commit 005d9575222afc98a663949417a0d02dc5020b54
Author:     Jan Klemkow <[email protected]>
AuthorDate: Sun Apr 5 23:12:32 2020 +0200
Commit:     Jan Klemkow <[email protected]>
CommitDate: Sun Apr 5 23:13:13 2020 +0200

    fix wrong continue in double stacked for loop

diff --git a/scroll.c b/scroll.c
index 79c6357..37eaf42 100644
--- a/scroll.c
+++ b/scroll.c
@@ -419,7 +419,7 @@ main(int argc, char *argv[])
                                                scrollup(rules[i].lines);
                                        if (rules[i].event == SCROLL_DOWN)
                                                scrolldown(buf, pos, 
rules[i].lines);
-                                       continue;
+                                       goto out;
                                }
                        }
  noevent:
@@ -429,6 +429,7 @@ main(int argc, char *argv[])
                        if (bottom != TAILQ_FIRST(&head))
                                jumpdown(buf, pos);
                }
+ out:
                if (pfd[1].revents & POLLIN) {
                        ssize_t n = read(mfd, input, sizeof input);
 

Reply via email to