- expandMacro() wants the next \0 character to be returned, which might
or might not be the same as lastc passed to grabArgs()
- use memcpy() instead of memmove() for the copy, the areas can't overlap
{ ARGV_t av = NULL;
char *s = xcalloc((lastc-se)+1, sizeof(*s));
- memmove(s, se, (lastc-se));
- ret = se + strlen(s) + 1;
+ /* XXX expandMacro() expects next \0 which can be beyond lastc */
+ ret = strchr(se, '\0');
+ memcpy(s, se, (lastc-se));
+
argvSplit(&av, s, " ");
argvAppend(&argv, av);