Ingo, Jorgen,
I pushed the patch. Here are some notes about your requests and suggestions.
<Jorgen>
> SUGGESTIONS:
> ------------
> 1. Consider adding a "set global backupdir" loop.
I decided to skip this as I am certain I have the problem fixed.
However, if we encounter it again we may want to consider setting up
something in Nuts.
...
> --let $i=1000000
> while ($i)
> {
> set global backupdir=@@datadir;
> --dec $i
> }
<Ingo>
>> Requests:
>> =========
>> [1] I need an English lesson.
Sentence struck. I was an idiot that day. :P
>> [3] Good. But please add two extra tests for "backupdir" and the two log
>> files in the other test each.
Done.
> Suggestions:
>> ============
>> [2] Not part of your patch. But Rafal just asked me to mask out warning
>> numbers in tests. If you agree that we should do that, please change it
>> here as an unrelated fix.
Done.
>> [4] I wonder if we shouldn't have >= here.
>> [5] I wonder if we shouldn't have >= here.
I looked through the code and it seems the only time a check for
FN_REFLEN is >= is for truncation. Other places use simply > -- so I did
not change the code.
>> [7] Good. Just a comment on the variable names in this function.
Excellent suggestion! Code refactored per your suggestion.
>> Ideas:
>> ======
>> [6] Also it might be good to deduce 2. One for the path delimiter ('/'
>> or '\') and one for at least one character of a file name. OTOH, if we
>> create backup files from "backupdir" in local, allocated memory only,
>> and not in a fixed size array, we may expire FN_REFLEN. Then this idea
>> is void.
I didn't do this because (to me) the slashes and whatnot are part of the
512 characters.
>> [8] I wonder if it might be a good idea to add an argument here:
>>
>> eng "The path specified for %.64s is too long."
>>
>> And then insert the variable name when using ER_PATH_LENGTH. This is not
>> an issue for "SET varname" statements as the name is obvious here. But
>> if the error message will later be used in other contexts, it might
>> become handy.
Another excellent suggestion. Done.
Chuck