mirror of
https://github.com/krahets/hello-algo.git
synced 2026-04-28 12:31:51 +08:00
fix memory leak in the C code (#1203)
* fix memory leak when size(deque) == 1 * fix memory leak
This commit is contained in:
@@ -49,6 +49,9 @@ void delHashMapOpenAddressing(HashMapOpenAddressing *hashMap) {
|
||||
free(pair);
|
||||
}
|
||||
}
|
||||
free(hashMap->buckets);
|
||||
free(hashMap->TOMBSTONE);
|
||||
free(hashMap);
|
||||
}
|
||||
|
||||
/* 哈希函数 */
|
||||
|
||||
Reference in New Issue
Block a user