diff options
author | Hallvard B Furuseth <h.b.furuseth@usit.uio.no> | 1997-04-25 09:45:10 +1200 |
---|---|---|
committer | Chip Salzenberg <chip@atlantic.net> | 1997-04-27 00:00:00 +1200 |
commit | 324aa91a3e6fd44523a86df7c5575563c5adf45c (patch) | |
tree | 4ff267f6774abaaf4157a9a978dc8db1b1a294e1 /pp_sys.c | |
parent | 8a38ab241313ca4a51b5fc5b36b207cdb71be4db (diff) | |
download | perl-324aa91a3e6fd44523a86df7c5575563c5adf45c.tar.gz |
Eliminate Alpha warnings
Signed-off-by: Hallvard B Furuseth <h.b.furuseth@usit.uio.no>
Diffstat (limited to 'pp_sys.c')
-rw-r--r-- | pp_sys.c | 15 |
1 files changed, 6 insertions, 9 deletions
@@ -1502,7 +1502,7 @@ PP(pp_ioctl) unsigned int func = U_I(POPn); int optype = op->op_type; char *s; - int retval; + IV retval; GV *gv = (GV*)POPs; IO *io = GvIOn(gv); @@ -1513,22 +1513,19 @@ PP(pp_ioctl) if (SvPOK(argsv) || !SvNIOK(argsv)) { STRLEN len; + STRLEN need; s = SvPV_force(argsv, len); - retval = IOCPARM_LEN(func); - if (len < retval) { - s = Sv_Grow(argsv, retval+1); - SvCUR_set(argsv, retval); + need = IOCPARM_LEN(func); + if (len < need) { + s = Sv_Grow(argsv, need + 1); + SvCUR_set(argsv, need); } s[SvCUR(argsv)] = 17; /* a little sanity check here */ } else { retval = SvIV(argsv); -#ifdef DOSISH - s = (char*)(long)retval; /* ouch */ -#else s = (char*)retval; /* ouch */ -#endif } TAINT_PROPER(optype == OP_IOCTL ? "ioctl" : "fcntl"); |