geoff 02/05/29 09:25:41
Modified: . Changes
src/modules/perl mod_perl_xs.h
Log:
fix get_set_PVp() to properly set NULL values when passing in undef
Submitted by: Stephen Clouse <[EMAIL PROTECTED]>
Reviewed by: dougm
Revision Changes Path
1.646 +4 -0 modperl/Changes
Index: Changes
===================================================================
RCS file: /home/cvs/modperl/Changes,v
retrieving revision 1.645
retrieving revision 1.646
diff -u -r1.645 -r1.646
--- Changes 23 May 2002 04:21:06 -0000 1.645
+++ Changes 29 May 2002 16:25:40 -0000 1.646
@@ -10,6 +10,10 @@
=item 1.26_01-dev
+fix get_set_PVp() to properly set NULL values when passing in undef
+thanks to Lyle Brooks for the spot
+[Stephen Clouse <[EMAIL PROTECTED]>]
+
Apache::Registry errors are now saved in $r->notes('error-notes')
[Jesse Erlbaum <[EMAIL PROTECTED]>]
1.7 +1 -1 modperl/src/modules/perl/mod_perl_xs.h
Index: mod_perl_xs.h
===================================================================
RCS file: /home/cvs/modperl/src/modules/perl/mod_perl_xs.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- mod_perl_xs.h 2 Mar 2000 23:23:10 -0000 1.6
+++ mod_perl_xs.h 29 May 2002 16:25:40 -0000 1.7
@@ -3,7 +3,7 @@
#define get_set_PVp(thing,p) \
RETVAL = (char*)thing; \
if(items > 1) \
- thing = (char*)((ST(1) == &sv_undef) ? NULL : pstrdup(p, SvPV(ST(1),na)))
+ thing = (char*)(SvOK(ST(1)) ? pstrdup(p, SvPV(ST(1),na)) : NULL)
#define get_set_PV(thing) \
get_set_PVp(thing,r->pool)