[Templates-cvs] cvs commit: Template2/xs Stash.xs
cvs@template-toolkit.org
cvs@template-toolkit.org
cvs 06/01/30 16:51:03
Modified: xs Stash.xs
Log:
* applied patch from Slaven Rezic to use SvOK(*value) rather than
(*value != &PL_sv_undef)
Revision Changes Path
1.19 +4 -3 Template2/xs/Stash.xs
Index: Stash.xs
===================================================================
RCS file: /template-toolkit/Template2/xs/Stash.xs,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- Stash.xs 2006/01/30 13:33:25 1.18
+++ Stash.xs 2006/01/30 16:51:02 1.19
@@ -26,7 +26,7 @@
*
*---------------------------------------------------------------------
*
-* $Id: Stash.xs,v 1.18 2006/01/30 13:33:25 abw Exp $
+* $Id: Stash.xs,v 1.19 2006/01/30 16:51:02 abw Exp $
*
*=====================================================================*/
@@ -89,7 +89,7 @@
static SV* scalar_dot_defined(pTHX_ SV*, AV*);
static SV* scalar_dot_length(pTHX_ SV*, AV*);
-static char rcsid[] = "$Id: Stash.xs,v 1.18 2006/01/30 13:33:25 abw Exp $";
+static char rcsid[] = "$Id: Stash.xs,v 1.19 2006/01/30 16:51:02 abw Exp $";
#define THROW_SIZE 64
static char throw_str[THROW_SIZE+1];
@@ -161,10 +161,11 @@
return TT_RET_CODEREF;
}
- else if (*value != &PL_sv_undef) {
+ else if (SvOK(*value)) {
*result = *value;
return TT_RET_OK;
}
+
}
*result = &PL_sv_undef;