(quote1): fix % quoting bug
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@5141 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -1392,18 +1392,18 @@ void
|
|||||||
quote1(char *initial, int argc, char **argv)
|
quote1(char *initial, int argc, char **argv)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
char buf[BUFSIZ]; /* must be >= sizeof(line) */
|
char buf[BUFSIZ]; /* must be >= sizeof(line) */
|
||||||
|
|
||||||
strcpy_truncate(buf, initial, sizeof(buf));
|
strcpy_truncate(buf, initial, sizeof(buf));
|
||||||
for(i = 1; i < argc; i++) {
|
for(i = 1; i < argc; i++) {
|
||||||
if(i > 1)
|
if(i > 1)
|
||||||
strcat_truncate(buf, " ", sizeof(buf));
|
strcat_truncate(buf, " ", sizeof(buf));
|
||||||
strcat_truncate(buf, argv[i], sizeof(buf));
|
strcat_truncate(buf, argv[i], sizeof(buf));
|
||||||
}
|
}
|
||||||
if (command(buf) == PRELIM) {
|
if (command("%s", buf) == PRELIM) {
|
||||||
while (getreply(0) == PRELIM)
|
while (getreply(0) == PRELIM)
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
Reference in New Issue
Block a user