[td-225] refactor codes.
This commit is contained in:
parent
fa560fd3a7
commit
3b80eb7255
|
@ -276,7 +276,7 @@ void *taosCachePut(SCacheObj *pCacheObj, const void *key, size_t keyLen, const v
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
__cache_wr_lock(pCacheObj);
|
__cache_rd_lock(pCacheObj);
|
||||||
SCacheDataNode **pt = (SCacheDataNode **)taosHashGet(pCacheObj->pHashTable, key, keyLen);
|
SCacheDataNode **pt = (SCacheDataNode **)taosHashGet(pCacheObj->pHashTable, key, keyLen);
|
||||||
SCacheDataNode * pOld = (pt != NULL) ? (*pt) : NULL;
|
SCacheDataNode * pOld = (pt != NULL) ? (*pt) : NULL;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue