diff options
Diffstat (limited to 'src/strgen')
-rw-r--r-- | src/strgen/strgen.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/strgen/strgen.cpp b/src/strgen/strgen.cpp index 236597cdd..167af24f0 100644 --- a/src/strgen/strgen.cpp +++ b/src/strgen/strgen.cpp @@ -327,9 +327,10 @@ static int TranslateArgumentIdx(int arg); static void EmitWordList(const char * const *words, uint nw) { PutByte(nw); - for (uint i = 0; i < nw; i++) PutByte(strlen(words[i])); + for (uint i = 0; i < nw; i++) PutByte(strlen(words[i]) + 1); for (uint i = 0; i < nw; i++) { for (uint j = 0; words[i][j] != '\0'; j++) PutByte(words[i][j]); + PutByte(0); } } |