This commit is contained in:
Haojun Liao 2020-08-01 13:50:42 +08:00
parent adcbb40fbe
commit 2b413844d3
1 changed files with 5 additions and 3 deletions

View File

@ -298,11 +298,13 @@ void *taosHashGetCB(SHashObj *pHashObj, const void *key, size_t keyLen, void (*f
}
SHashNode *pNode = doSearchInEntryList(pe, key, keyLen, hashVal);
if (fp != NULL) {
fp(pNode->data);
if (pNode != NULL) {
if (fp != NULL) {
fp(pNode->data);
}
data = pNode->data;
}
data = pNode->data;
if (pHashObj->type == HASH_ENTRY_LOCK) {
taosRUnLockLatch(&pe->latch);
}