projects
/
silc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
updates.
[silc.git]
/
lib
/
silccrypt
/
silchash.c
diff --git
a/lib/silccrypt/silchash.c
b/lib/silccrypt/silchash.c
index 8bb7339336e98188d45ec00925a4c02b0527d3f5..58cecec9cb44225d0b0f2b450fe1ebb8dc6db15e 100644
(file)
--- a/
lib/silccrypt/silchash.c
+++ b/
lib/silccrypt/silchash.c
@@
-156,7
+156,7
@@
int silc_hash_alloc(const unsigned char *name, SilcHash *new_hash)
h = h->next;
}
- if (!h)
+ if (!h
|| !h->hash->context_len
)
goto check_builtin;
/* Set the pointers */
@@
-174,6
+174,7
@@
int silc_hash_alloc(const unsigned char *name, SilcHash *new_hash)
if (silc_hash_builtin_list[i].name == NULL) {
silc_free(*new_hash);
+ *new_hash = NULL;
return FALSE;
}