Author: timbo
Date: Fri Nov 25 07:55:46 2005
New Revision: 2274
Modified:
dbi/trunk/DBI.xs
Log:
Fix core dump on DESTROY
Modified: dbi/trunk/DBI.xs
==============================================================================
--- dbi/trunk/DBI.xs (original)
+++ dbi/trunk/DBI.xs Fri Nov 25 07:55:46 2005
@@ -2433,7 +2433,8 @@ XS(XS_DBI_dispatch) /* prototype
/* However, we must at least modify DBIc_MY_H() as that is */
/* pointing (without a refcnt inc) to the scalar that is */
/* being destroyed, so it'll contain random values later. */
- DBIc_MY_H(imp_xxh) = (void*)SvRV(mg->mg_obj); /* inner (untied) HV
*/
+ if (imp_xxh)
+ DBIc_MY_H(imp_xxh) = (void*)SvRV(mg->mg_obj); /* inner (untied)
HV */
XSRETURN(0);
}