On Mon, 29 Oct 2007, Willy Tarreau wrote:
<CUT>
> Could you please move this just above MAX_LINE_ARGS, a few lines
> below,
Of course.
> and maybe at the same time increase MAX_LINE_ARGS ?
64? 128?
>> @@ -2323,6 +2323,15 @@ int readcfgfile(const char *file) >> >> end = line + strlen(line); >> >> + if (*(end-1) != '\n' && strlen(line) + 1 == sizeof(thisline)) { >> + /* Check if the last char is not \n and we reached the limit. Watch out >> + * for the last line without the terminating '\n'! >> + */ >
Some editors (like mcedit for example) are able to create a file without a terminating '\n' on the last line. I know that it is wrong but... So, I would like to distinguish such situation from a truncated line as the application should not reject such files, especially with a misleading error message.
Best regards,
Krzysztof Olędzki Received on 2007/10/29 00:17
This archive was generated by hypermail 2.2.0 : 2007/11/04 19:21 CET