diff options
author | Albert Dvornik <bert@genscan.com> | 1999-05-03 08:20:57 -0400 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1999-05-10 10:00:11 +0000 |
commit | 27533608423d4f8b8ffa4951b5d211f972816882 (patch) | |
tree | 013c4ef8fb79d894ea5de973d62b47a3ff2a9836 /dump.c | |
parent | 8c0bfa080e85353d7675b8b2fb1a04c6cc60cd5f (diff) | |
download | perl-27533608423d4f8b8ffa4951b5d211f972816882.tar.gz |
do_sv_dump does dump (core) on IO handles
Message-ID: <tqlnf6gm52.fsf@puma.genscan.com>
p4raw-id: //depot/perl@3368
Diffstat (limited to 'dump.c')
-rw-r--r-- | dump.c | 14 |
1 files changed, 10 insertions, 4 deletions
@@ -1100,14 +1100,20 @@ do_sv_dump(I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bool dumpops, dump_indent(level, file, " PAGE = %ld\n", (long)IoPAGE(sv)); dump_indent(level, file, " PAGE_LEN = %ld\n", (long)IoPAGE_LEN(sv)); dump_indent(level, file, " LINES_LEFT = %ld\n", (long)IoLINES_LEFT(sv)); - dump_indent(level, file, " TOP_NAME = \"%s\"\n", IoTOP_NAME(sv)); + if (IoTOP_NAME(sv)) + dump_indent(level, file, " TOP_NAME = \"%s\"\n", IoTOP_NAME(sv)); do_gv_dump (level, file, " TOP_GV", IoTOP_GV(sv)); - dump_indent(level, file, " FMT_NAME = \"%s\"\n", IoFMT_NAME(sv)); + if (IoFMT_NAME(sv)) + dump_indent(level, file, " FMT_NAME = \"%s\"\n", IoFMT_NAME(sv)); do_gv_dump (level, file, " FMT_GV", IoFMT_GV(sv)); - dump_indent(level, file, " BOTTOM_NAME = \"%s\"\n", IoBOTTOM_NAME(sv)); + if (IoBOTTOM_NAME(sv)) + dump_indent(level, file, " BOTTOM_NAME = \"%s\"\n", IoBOTTOM_NAME(sv)); do_gv_dump (level, file, " BOTTOM_GV", IoBOTTOM_GV(sv)); dump_indent(level, file, " SUBPROCESS = %ld\n", (long)IoSUBPROCESS(sv)); - dump_indent(level, file, " TYPE = %c\n", IoTYPE(sv)); + if (isPRINT(IoTYPE(sv))) + dump_indent(level, file, " TYPE = '%c'\n", IoTYPE(sv)); + else + dump_indent(level, file, " TYPE = '\\%o'\n", IoTYPE(sv)); dump_indent(level, file, " FLAGS = 0x%lx\n", (long)IoFLAGS(sv)); break; } |