diff options
author | tavianator <tavianator@antimatter.localdomain> | 2009-11-24 00:41:27 -0500 |
---|---|---|
committer | tavianator <tavianator@antimatter.localdomain> | 2009-11-24 00:41:27 -0500 |
commit | e5f268e84dbe121d063de8ec73ad53c36b9e8d83 (patch) | |
tree | 0059c2446481e2eda552d277a716e4fd26eab45a /dimension | |
parent | a7bb341bc683f4d43bdddadd66f72234127b9060 (diff) | |
download | dimension-e5f268e84dbe121d063de8ec73ad53c36b9e8d83.tar.xz |
Fix off-by-one in string lexing.
Diffstat (limited to 'dimension')
-rw-r--r-- | dimension/flex.l | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dimension/flex.l b/dimension/flex.l index b470159..8c3008d 100644 --- a/dimension/flex.l +++ b/dimension/flex.l @@ -80,7 +80,7 @@ #define STRCAT(str, len) \ do { \ token.value = realloc(token.value, string_length + len + 1); \ - strncpy(token.value + string_length, str, len); \ + strncpy(token.value + string_length, str, len + 1); \ string_length += len; \ CALCULATE_COLUMN(); \ } while(0) |