File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -247,8 +247,10 @@ static void __console_drawc(int c)
247247 ptr = __console_get_cursor_start_ptr ();
248248
249249 pbits = & con -> font .gfx [c * FONT_YSIZE ];
250- // con_stride is in bytes, but we increment ptr which isn't a byte pointer
251- // and the work in the loop already increments ptr 4 times before needing to go to the next row
250+ // con_stride is in bytes, but we increment ptr which is an int pointer
251+ // -> we have to divide to not skip over rows we want to write to
252+ // the work in the loop already writes 4 ints before going to the next row
253+ // -> subtract that 4 here, so nextline can be directly added to ptr later
252254 nextline = con -> con_stride /sizeof (* ptr ) - 4 ;
253255
254256 fgcolor = currentConsole -> fg ;
You can’t perform that action at this time.
0 commit comments