diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 1998-06-18 16:33:01 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1998-06-18 16:33:01 +0000 |
commit | 00db4c452819e776e72467584ab4e9617d012f7b (patch) | |
tree | a0211b478efd413d7b381a4a612d15e1a33036d8 /doio.c | |
parent | 3b818b81e61465ce5ae6f7c21e6ca3b83d30216e (diff) | |
download | perl-00db4c452819e776e72467584ab4e9617d012f7b.tar.gz |
fix memory leaks and uninitialized memory accesses found by Purify
p4raw-id: //depot/perl@1143
Diffstat (limited to 'doio.c')
-rw-r--r-- | doio.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -258,7 +258,7 @@ do_open(GV *gv, register char *name, I32 len, int as_raw, int rawmode, int rawpe else fp = PerlIO_open(name,mode); } - else if (name[len-1] == '|') { + else if (len > 1 && name[len-1] == '|') { name[--len] = '\0'; while (len && isSPACE(name[len-1])) name[--len] = '\0'; |