pgsql: Use SvROK(sv) rather than directly checking SvTYPE(sv) == SVt_RV

From: tgl(at)postgresql(dot)org (Tom Lane)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Use SvROK(sv) rather than directly checking SvTYPE(sv) == SVt_RV
Date: 2010-03-09 22:35:07
Message-ID: 20100309223507.B1E707541D0@cvs.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Log Message:
-----------
Use SvROK(sv) rather than directly checking SvTYPE(sv) == SVt_RV in plperl.
The latter is considered unwarranted chumminess with the implementation,
and can lead to crashes with recent Perl versions.

Report and fix by Tim Bunce. Back-patch to all versions containing the
questionable coding pattern.

Tags:
----
REL8_2_STABLE

Modified Files:
--------------
pgsql/src/pl/plperl:
plperl.c (r1.123.2.11 -> r1.123.2.12)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/pl/plperl/plperl.c?r1=1.123.2.11&r2=1.123.2.12)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2010-03-09 22:35:16 pgsql: Use SvROK(sv) rather than directly checking SvTYPE(sv) == SVt_RV
Previous Message Tom Lane 2010-03-09 22:34:59 pgsql: Use SvROK(sv) rather than directly checking SvTYPE(sv) == SVt_RV