diff options
| author | Peter Stephenson <pws@users.sourceforge.net> | 2008-08-22 15:41:31 +0000 |
|---|---|---|
| committer | Peter Stephenson <pws@users.sourceforge.net> | 2008-08-22 15:41:31 +0000 |
| commit | 9fe735e663507164a61341c998247328fa2a738b (patch) | |
| tree | f749052fceb4aaad76c214b03ce5c3f76d1beee4 /Src/exec.c | |
| parent | Alexey I. Froloff: 25459: add list-dirs-first style. (diff) | |
| download | zsh-9fe735e663507164a61341c998247328fa2a738b.tar zsh-9fe735e663507164a61341c998247328fa2a738b.tar.gz zsh-9fe735e663507164a61341c998247328fa2a738b.tar.bz2 zsh-9fe735e663507164a61341c998247328fa2a738b.tar.lz zsh-9fe735e663507164a61341c998247328fa2a738b.tar.xz zsh-9fe735e663507164a61341c998247328fa2a738b.tar.zst zsh-9fe735e663507164a61341c998247328fa2a738b.zip | |
25508: set file name if function came from dump file
Diffstat (limited to 'Src/exec.c')
| -rw-r--r-- | Src/exec.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Src/exec.c b/Src/exec.c index 08986afc3..4cd97b3df 100644 --- a/Src/exec.c +++ b/Src/exec.c @@ -4406,8 +4406,11 @@ getfpfunc(char *s, int *ksh, char **fname) sprintf(buf, "%s/%s", *pp, s); else strcpy(buf, s); - if ((r = try_dump_file(*pp, s, buf, ksh))) + if ((r = try_dump_file(*pp, s, buf, ksh))) { + if (fname) + *fname = ztrdup(buf); return r; + } unmetafy(buf, NULL); if (!access(buf, R_OK) && (fd = open(buf, O_RDONLY | O_NOCTTY)) != -1) { if ((len = lseek(fd, 0, 2)) != -1) { |
