From: Wilfried Göesgens Date: Sat, 10 May 2008 08:42:41 +0000 (+0000) Subject: * made GetCount NULL pointer aware since its safe to say that a non existant hash... X-Git-Tag: v7.86~2273 X-Git-Url: https://code.citadel.org/?p=citadel.git;a=commitdiff_plain;h=2b0e94ef0c013191d5a1991796bd845ab424277e * made GetCount NULL pointer aware since its safe to say that a non existant hash has 0 entries. --- diff --git a/libcitadel/lib/hash.c b/libcitadel/lib/hash.c index 3908121d9..65d0519b5 100644 --- a/libcitadel/lib/hash.c +++ b/libcitadel/lib/hash.c @@ -165,6 +165,7 @@ HashList *NewHash(int Uniq, HashFunc F) int GetCount(HashList *Hash) { + if(Hash==NULL) return 0; return Hash->nMembersUsed; }