return DICT_ERR if expand failed due to memory allocation failure */
| 194 | |
| 195 | /* return DICT_ERR if expand failed due to memory allocation failure */ |
| 196 | int dictTryExpand(dict *d, unsigned long size) { |
| 197 | int malloc_failed; |
| 198 | _dictExpand(d, size, &malloc_failed); |
| 199 | return malloc_failed? DICT_ERR : DICT_OK; |
| 200 | } |
| 201 | |
| 202 | /* Performs N steps of incremental rehashing. Returns 1 if there are still |
| 203 | * keys to move from the old to the new hash table, otherwise 0 is returned. |
no test coverage detected