summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bfinter2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/bfinter2.c b/bfinter2.c
index 8801090..924d35f 100644
--- a/bfinter2.c
+++ b/bfinter2.c
@@ -184,7 +184,7 @@ static void p_run(const struct program p){
case IDEBUG: {
int low=0,high=memsize-1;
while(low<startidx&&mem[low]==0)low++;
- while(high>startidx&&mem[high]==0)high++;
+ while(high>startidx&&mem[high]==0)high--;
for(int i=low;i<=high;i++){
fprintf(stderr,"%3u ",(unsigned)mem[i]);
}