Skip to content

Commit

Permalink
GrainBuf: fix error handling
Browse files Browse the repository at this point in the history
Signed-off-by: Tim Blechmann <tim@klingt.org>

git-svn-id: https://supercollider.svn.sourceforge.net/svnroot/supercollider/trunk@9910 a380766d-ff14-0410-b294-a243070f3f08
  • Loading branch information
Tim Blechmann committed Mar 1, 2010
1 parent b9f1c37 commit a4fe3bc
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions common/Source/plugins/GrainUGens.cpp
Expand Up @@ -1090,8 +1090,8 @@ inline void GrainBuf_next_play_active(GrainBuf *unit, int inNumSamples)


if (!bufData) { if (!bufData) {
grain->counter -= inNumSamples; grain->counter -= inNumSamples;
GrainBuf_grain_cleanup(unit, grain); if (!GrainBuf_grain_cleanup(unit, grain))
++i; ++i;
continue; continue;
} }


Expand All @@ -1114,13 +1114,6 @@ inline void GrainBuf_next_play_active(GrainBuf *unit, int inNumSamples)
else else
GRAIN_BUF_PLAY_GRAIN(CUSTOM); GRAIN_BUF_PLAY_GRAIN(CUSTOM);



if (grain->counter <= 0) {
*grain = unit->mGrains[--unit->mNumActive]; // remove grain
continue;
}
++i;

if (GrainBuf_grain_cleanup(unit, grain)) if (GrainBuf_grain_cleanup(unit, grain))
continue; continue;
++i; ++i;
Expand Down

0 comments on commit a4fe3bc

Please sign in to comment.