В ср, 17.12.2003, в 00:25, Dag-Erling Smørgrav пишет: > "Vladimir B. Grebenschikov" <vova_at_fbsd.ru> writes: > > Do you know why pkg_add threat character \' as invalid ? > > No idea. I suggest you RTFS. Looking source shows that pkg_add construct one striing for system(3) and populate this string with filenames in ' add_count = snprintf(&perm_args[perm_count], maxargs - perm_count, "'%s' ", p->name); if (add_count < 0 || add_count > maxargs - perm_count) { cleanup(0); errx(2, "%s: oops, miscounted strings!", __func__); } ... #define PUSHOUT(todir) /* push out string */ \ if (where_count > (int)sizeof(STARTSTRING)-1) { \ strcat(where_args, "|tar --unlink -xpf - -C "); \ strcat(where_args, todir); \ if (system(where_args)) { \ cleanup(0); \ errx(2, \ "%s: can not invoke %ld byte tar pipeline: %s", \ __func__, \ (long)strlen(where_args), where_args); \ } \ strcpy(where_args, STARTSTRING); \ where_count = sizeof(STARTSTRING)-1; \ } \ > DES -- Vladimir B. Grebenschikov <vova_at_fbsd.ru> SWsoft Inc.Received on Tue Dec 16 2003 - 23:19:52 UTC
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:34 UTC