Kajus
-
Posts
2 -
Joined
-
Last visited
Content Type
Forums
Store
Downloads
Blogs
Posts posted by Kajus
-
-
Hi,
is there any specific reason why gwinPrintg function can only be used if the gfile is enabled (and therefore also one of the file backends as the compilation fails with no backed enabled). I find this function quite handy, but as I don't use ugfx filesystem api, I don't want to enable the whole gfile stuff...Thanks you,
Jakub
Bug in Console scrollBuffer
in Development and Feedback
Posted
Hi,
there's a bug in console scrollBuffer function, consider following scenario:
gcw->buffer = 0x0000
gcw->buffer[0] = A
gcw->buffer[1] = \n
gcw->bufpos = 1
ep becomes 0x0001, therefore for cycle exits with p = 0x0001, which is outside the used bufer area, but the if condition is found invalid as 0x0001 contains \n, dp becomes 2 and here's the bug: gcw->bufpos = bufpos - dp = 1 - 2 = overflow to very high number, memcpy overwrites huge area of memory and finally MCU crashes.
I guess the if condition should be something like:
if (*p == ep || *p != '\n')...