diff options
Diffstat (limited to 'examples/c/reccalc/scan.l')
-rw-r--r-- | examples/c/reccalc/scan.l | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/c/reccalc/scan.l b/examples/c/reccalc/scan.l index 0bf5210c..45d70d3b 100644 --- a/examples/c/reccalc/scan.l +++ b/examples/c/reccalc/scan.l @@ -32,9 +32,9 @@ do \ capacity = capacity ? 2 * capacity : 128; \ while (capacity < size + yyleng + 1); \ - str = realloc (str, capacity); \ + str = realloc (str, (size_t) capacity); \ } \ - memcpy (str + size, yytext, yyleng); \ + memcpy (str + size, yytext, (size_t) yyleng); \ size += yyleng; \ assert (size < capacity); \ } while (0) |