GV * const wgv = MUTABLE_GV(POPs);
GV * const rgv = MUTABLE_GV(POPs);
- if (!rgv || !wgv)
- goto badexit;
-
- if (!isGV_with_GP(rgv) || !isGV_with_GP(wgv))
- DIE(aTHX_ PL_no_usym, "filehandle");
+ assert (isGV_with_GP(rgv));
+ assert (isGV_with_GP(wgv));
rstio = GvIOn(rgv);
wstio = GvIOn(wgv);
const unsigned int func = POPu;
const int optype = PL_op->op_type;
GV * const gv = MUTABLE_GV(POPs);
- IO * const io = gv ? GvIOn(gv) : NULL;
+ IO * const io = GvIOn(gv);
char *s;
IV retval;
- if (!io || !argsv || !IoIFP(io)) {
+ if (!IoIFP(io)) {
report_evil_fh(gv);
SETERRNO(EBADF,RMS_IFI); /* well, sort of... */
RETPUSHUNDEF;
STRLEN len;
int op_type;
- if (!io || !IoIFP(io))
+ if (!IoIFP(io))
goto nuts;
addr = SvPV_const(addrsv, len);
dVAR; dSP;
const int backlog = POPi;
GV * const gv = MUTABLE_GV(POPs);
- IO * const io = gv ? GvIOn(gv) : NULL;
+ IO * const io = GvIOn(gv);
- if (!io || !IoIFP(io))
+ if (!IoIFP(io))
goto nuts;
if (PerlSock_listen(PerlIO_fileno(IoIFP(io)), backlog) >= 0)
{
dVAR; dSP; dTARGET;
IO *nstio;
- IO *gstio;
char namebuf[MAXPATHLEN];
#if (defined(VMS_DO_SOCKETS) && defined(DECCRTL_SOCKETS)) || defined(__QNXNTO__)
Sock_size_t len = sizeof (struct sockaddr_in);
GV * const ngv = MUTABLE_GV(POPs);
int fd;
- if (!ngv)
- goto badexit;
- if (!ggv)
- goto nuts;
-
- gstio = GvIO(ggv);
+ IO * const gstio = GvIO(ggv);
if (!gstio || !IoIFP(gstio))
goto nuts;
GV * const gv = MUTABLE_GV(POPs);
IO * const io = GvIOn(gv);
- if (!io || !IoIFP(io))
+ if (!IoIFP(io))
goto nuts;
PUSHi( PerlSock_shutdown(PerlIO_fileno(IoIFP(io)), how) >= 0 );
GV * const gv = MUTABLE_GV(POPs);
IO * const io = GvIOn(gv);
- if (!io)
- goto nope;
-
if ((IoIFP(io) || IoOFP(io)))
Perl_ck_warner_d(aTHX_ packWARN2(WARN_IO, WARN_DEPRECATED),
"Opening filehandle %"HEKf" also as a directory",
const Direntry_t *dp;
IO * const io = GvIOn(gv);
- if (!io || !IoDIRP(io)) {
+ if (!IoDIRP(io)) {
Perl_ck_warner(aTHX_ packWARN(WARN_IO),
"readdir() attempted on invalid dirhandle %"HEKf,
HEKfARG(GvENAME_HEK(gv)));
GV * const gv = MUTABLE_GV(POPs);
IO * const io = GvIOn(gv);
- if (!io || !IoDIRP(io)) {
+ if (!IoDIRP(io)) {
Perl_ck_warner(aTHX_ packWARN(WARN_IO),
"telldir() attempted on invalid dirhandle %"HEKf,
HEKfARG(GvENAME_HEK(gv)));
GV * const gv = MUTABLE_GV(POPs);
IO * const io = GvIOn(gv);
- if (!io || !IoDIRP(io)) {
+ if (!IoDIRP(io)) {
Perl_ck_warner(aTHX_ packWARN(WARN_IO),
"seekdir() attempted on invalid dirhandle %"HEKf,
HEKfARG(GvENAME_HEK(gv)));
GV * const gv = MUTABLE_GV(POPs);
IO * const io = GvIOn(gv);
- if (!io || !IoDIRP(io)) {
+ if (!IoDIRP(io)) {
Perl_ck_warner(aTHX_ packWARN(WARN_IO),
"rewinddir() attempted on invalid dirhandle %"HEKf,
HEKfARG(GvENAME_HEK(gv)));
GV * const gv = MUTABLE_GV(POPs);
IO * const io = GvIOn(gv);
- if (!io || !IoDIRP(io)) {
+ if (!IoDIRP(io)) {
Perl_ck_warner(aTHX_ packWARN(WARN_IO),
"closedir() attempted on invalid dirhandle %"HEKf,
HEKfARG(GvENAME_HEK(gv)));