Skip to content

Commit

Permalink
Extend series before assign the last character
Browse files Browse the repository at this point in the history
Or the last character will be missing, as tail is not set before
extending and Extend_Series only copy content up to "tail", and
terminate the new series, which clears the newly assigned value
(by "chr").

Fixes Atronix bug rebol#85
  • Loading branch information
zsx committed Apr 6, 2015
1 parent 737c9a7 commit 2e56b0c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/l-scan.c
Expand Up @@ -457,10 +457,10 @@

src++;

*UNI_SKIP(buf, buf->tail) = chr;

if (SERIES_LEN(buf) >= SERIES_REST(buf)) Extend_Series(buf, 1);

*UNI_SKIP(buf, buf->tail) = chr;

buf->tail ++;
}

Expand Down

0 comments on commit 2e56b0c

Please sign in to comment.