Make args replace ... only at the end of file (#909)

So that the string '...' can be used verbatim elsewhere in the file.
This commit is contained in:
mataha 2023-11-08 19:00:52 +01:00 committed by GitHub
parent ac125d3e1f
commit cc3e3de044
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -81,7 +81,7 @@ int LoadZipArgsImpl(int *argc, char ***argv, char *data) {
founddots = false;
AddZipArg(&n, &args, (*argv)[0]);
while ((arg = strtok_r(start, "\r\n", &state))) {
if (!strcmp(arg, "...")) {
if (!strcmp(arg, "...") && !state) {
founddots = true;
for (i = 1; i < *argc; ++i) {
AddZipArg(&n, &args, (*argv)[i]);