...like returning a pointer to the stack:
char *dupstr(const char *src) {
char new[1024];
strlcpy(new, src, 1024);
return new;
}