check for NULL handler.

This commit is contained in:
Vitor Santos Costa 2011-07-22 04:21:21 -07:00
parent f6be2ed08d
commit 80966dd286

View File

@ -178,6 +178,8 @@ int Yap_CleanOpaqueVariable(CELL *pt)
if (!GLOBAL_OpaqueHandlers)
return FALSE;
blobp = (MP_INT *)(pt+2);
if (!GLOBAL_OpaqueHandlers[blob_info].fail_handler)
return TRUE;
return (GLOBAL_OpaqueHandlers[blob_info].fail_handler)((void *)(blobp+1));
}