cabinet: Fix a potential NULL reference.

This commit is contained in:
Jeff Latimer 2007-06-27 22:10:38 +10:00 committed by Alexandre Julliard
parent fb1082ae73
commit 33af21fdcf

View file

@ -173,7 +173,11 @@ HFCI __cdecl FCICreate(
int err;
PFCI_Int p_fci_internal;
if ((!perf) || (!pfnalloc) || (!pfnfree) || (!pfnopen) || (!pfnread) ||
if (!perf) {
SetLastError(ERROR_BAD_ARGUMENTS);
return NULL;
}
if ((!pfnalloc) || (!pfnfree) || (!pfnopen) || (!pfnread) ||
(!pfnwrite) || (!pfnclose) || (!pfnseek) || (!pfndelete) ||
(!pfnfcigtf) || (!pccab)) {
perf->erfOper = FCIERR_NONE;