shithub: orca

Download patch

ref: 1758bfee21285b04b608f2bd7e415812ab802ac2
parent: 46cf15c59665357ea62f53b09e4a1ed22693ba15
author: cancel <cancel@cancel.fm>
date: Wed Jan 1 16:07:55 EST 2020

Fix incorrect index variable in debug print loop

Would cause bad memory read or infinite loop if the debug print was
enabled.

--- a/tui_main.c
+++ b/tui_main.c
@@ -612,7 +612,7 @@
       Oevent_osc_ints const* eo = &ev->osc_ints;
       wprintw(win, "OSC\t%c\tcount: %d ", eo->glyph, eo->count, eo->count);
       waddch(win, ACS_VLINE);
-      for (Usz j = 0; j < eo->count; ++i) {
+      for (Usz j = 0; j < eo->count; ++j) {
         wprintw(win, " %d", eo->numbers[j]);
       }
     } break;