diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2006-05-09 13:10:01 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2006-05-09 13:10:01 +0000 |
commit | 735fec840d57c71a7d7fbdc8ecb199c92bb3f870 (patch) | |
tree | e2cdff38656aa3d67e18be2c4cca698481df557f /op.c | |
parent | 5db49ba3a175392c88bf67c5576fcca80075f35e (diff) | |
download | perl-735fec840d57c71a7d7fbdc8ecb199c92bb3f870.tar.gz |
Fix a logic error in conditional found by Coverity
p4raw-id: //depot/perl@28136
Diffstat (limited to 'op.c')
-rw-r--r-- | op.c | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -6416,6 +6416,7 @@ Perl_ck_fun(pTHX_ OP *o) else if (kid->op_type == OP_AELEM || kid->op_type == OP_HELEM) { + OP *firstop; OP *op = ((BINOP*)kid)->op_first; name = NULL; if (op) { @@ -6425,10 +6426,10 @@ Perl_ck_fun(pTHX_ OP *o) "[]" : "{}"; if (((op->op_type == OP_RV2AV) || (op->op_type == OP_RV2HV)) && - (op = ((UNOP*)op)->op_first) && - (op->op_type == OP_GV)) { + (firstop = ((UNOP*)op)->op_first) && + (firstop->op_type == OP_GV)) { /* packagevar $a[] or $h{} */ - GV * const gv = cGVOPx_gv(op); + GV * const gv = cGVOPx_gv(firstop); if (gv) tmpstr = Perl_newSVpvf(aTHX_ |