Fix enqueueing bug
This commit is contained in:
parent
12d21e642f
commit
cf762d2c73
@ -204,7 +204,7 @@ void GCodeQueue::enqueue_now_P(PGM_P const pgcode) {
|
|||||||
PGM_P p = pgcode;
|
PGM_P p = pgcode;
|
||||||
for (;;) {
|
for (;;) {
|
||||||
char c;
|
char c;
|
||||||
while ((c = p[i]) && c != '\n') i++;
|
while ((c = pgm_read_byte(&p[i])) && c != '\n') i++;
|
||||||
char cmd[i + 1];
|
char cmd[i + 1];
|
||||||
memcpy_P(cmd, p, i);
|
memcpy_P(cmd, p, i);
|
||||||
cmd[i] = '\0';
|
cmd[i] = '\0';
|
||||||
|
Loading…
Reference in New Issue
Block a user