Skip to content

Commit

Permalink
Merge pull request #169 from cnuahs/crash-test
Browse files Browse the repository at this point in the history
Add a warning when loading a cic object from a crashed experiment.
  • Loading branch information
adammorrissirrommada committed Jun 7, 2021
2 parents 48a0be0 + 8ad3fe1 commit 93a332b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion +neurostim/cic.m
Original file line number Diff line number Diff line change
Expand Up @@ -2175,7 +2175,11 @@ function KbQueueStop(c)
storeInLog(c.prms.firstFrame,fakeFF,NaN)
end


% Check c.stage and issue a warning if this seems like a crashed session
if c.stage ~= neurostim.cic.POST
warning('This experiment ended unexpectedly (c.stage == %i; Should be %i). Some trials may be missing.', ...
c.stage,neurostim.cic.POST);
end

end

Expand Down

0 comments on commit 93a332b

Please sign in to comment.