diff options
author | Paul Warren <pdw@ex-parrot.com> | 2022-10-09 22:07:55 +0100 |
---|---|---|
committer | Paul Warren <pdw@ex-parrot.com> | 2022-10-09 22:07:55 +0100 |
commit | aee8e05f48f0ffee4a724c6bd582f51ca65b27f1 (patch) | |
tree | 76dab521c580e74095b55ba4c8ecf3c0561a9d2f /hash.c | |
parent | 8d76ef06d225c4d72db544b54ea1ef1a0e077967 (diff) |
Show local process names.origin/proc-display
Patch from Mark Benjamin
Diffstat (limited to 'hash.c')
-rw-r--r-- | hash.c | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -69,7 +69,12 @@ hash_status_enum hash_find(hash_type* hash_table, void* key, void **rec) { while (p && !hash_table->compare(p->key, key)) { p = p->next; } - if (!p) return HASH_STATUS_KEY_NOT_FOUND; + if (!p) { + if (hash_table->not_found_callback != NULL) { + hash_table->not_found_callback((void *)hash_table); + } + return HASH_STATUS_KEY_NOT_FOUND; + } *rec = p->rec; return HASH_STATUS_OK; } |