diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2003-08-30 18:47:02 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2003-08-30 18:47:02 +0000 |
commit | 3b6c1aba8481917ec21730e293e339a1c561e02c (patch) | |
tree | 644bf6495a2288a41254929c3f9f68c9d0210a85 /doio.c | |
parent | c2fcde81f9cb1a632422e27a9e967bc087d75ae7 (diff) | |
download | perl-3b6c1aba8481917ec21730e293e339a1c561e02c.tar.gz |
Fewer naked char constants.
p4raw-id: //depot/perl@20957
Diffstat (limited to 'doio.c')
-rw-r--r-- | doio.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -179,7 +179,7 @@ Perl_do_openn(pTHX_ GV *gv, register char *name, I32 len, int as_raw, (ismodifying & (O_CREAT|appendtrunc))) TAINT_PROPER("sysopen"); } - mode[ix++] = '#'; /* Marker to openn to use numeric "sysopen" */ + mode[ix++] = IoTYPE_NUMERIC; /* Marker to openn to use numeric "sysopen" */ #if defined(USE_64_BIT_RAWIO) && defined(O_LARGEFILE) rawmode |= O_LARGEFILE; /* Transparently largefiley. */ @@ -674,8 +674,8 @@ Perl_do_openn(pTHX_ GV *gv, register char *name, I32 len, int as_raw, if (IoTYPE(io) == IoTYPE_SOCKET || (IoTYPE(io) == IoTYPE_WRONLY && fd >= 0 && S_ISCHR(PL_statbuf.st_mode)) ) { char *s = mode; - if (*s == 'I' || *s == '#') - s++; + if (*s == IoTYPE_IMPLICIT || *s == IoTYPE_NUMERIC) + s++; *s = 'w'; if (!(IoOFP(io) = PerlIO_openn(aTHX_ type,s,fd,0,0,NULL,0,svp))) { PerlIO_close(fp); |