X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pp_sys.c;h=28ffcda5e1549109ea70278acc4da183f81360f1;hb=a6c71b5b9462db13c7bb2cd263cee5995315784c;hp=e35cfd4c2dbb4dff9563dfd7974e3f149b9dd55c;hpb=f7aaccc209ec5f90cb29b7b4871f5abef7db50d5;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pp_sys.c b/pp_sys.c index e35cfd4..28ffcda 100644 --- a/pp_sys.c +++ b/pp_sys.c @@ -57,7 +57,15 @@ extern "C" int syscall(unsigned long,...); #if defined(HAS_SOCKET) && !defined(VMS) /* VMS handles sockets via vmsish.h */ # include # if defined(USE_SOCKS) && defined(I_SOCKS) +# if !defined(INCLUDE_PROTOTYPES) +# define INCLUDE_PROTOTYPES /* for */ +# define PERL_SOCKS_NEED_PROTOTYPES +# endif # include +# ifdef PERL_SOCKS_NEED_PROTOTYPES /* keep cpp space clean */ +# undef INCLUDE_PROTOTYPES +# undef PERL_SOCKS_NEED_PROTOTYPES +# endif # endif # ifdef I_NETDB # include @@ -794,7 +802,13 @@ PP(pp_tie) POPSTACK; if (sv_isobject(sv)) { sv_unmagic(varsv, how); - sv_magic(varsv, (SvRV(sv) == varsv ? Nullsv : sv), how, Nullch, 0); + /* Croak if a self-tie on an aggregate is attempted. */ + if (varsv == SvRV(sv) && + (SvTYPE(sv) == SVt_PVAV || + SvTYPE(sv) == SVt_PVHV)) + Perl_croak(aTHX_ + "Self-ties of arrays and hashes are not supported"); + sv_magic(varsv, sv, how, Nullch, 0); } LEAVE; SP = PL_stack_base + markoff; @@ -2328,6 +2342,10 @@ PP(pp_accept) fcntl(fd, F_SETFD, fd > PL_maxsysfd); /* ensure close-on-exec */ #endif +#ifdef EPOC + len = sizeof saddr; /* EPOC somehow truncates info */ +#endif + PUSHp((char *)&saddr, len); RETURN; @@ -4968,8 +4986,10 @@ PP(pp_gpwent) sv_setpv(sv, spwent->sp_pwdp); } # endif +# ifdef PWPASSWD if (!SvPOK(sv)) /* Use the standard password, then. */ sv_setpv(sv, pwent->pw_passwd); +# endif # ifndef INCOMPLETE_TAINTS /* passwd is tainted because user himself can diddle with it.