| 53 |
|
|
| 54 |
static void trie_file_dict_cleanup_cb(const char *filename, int64_t shmid) |
static void trie_file_dict_cleanup_cb(const char *filename, int64_t shmid) |
| 55 |
{ |
{ |
|
log_std("Cleanup: %s %ld\n", filename, shmid); |
|
| 56 |
if (shmctl((int)shmid, IPC_RMID, NULL) == -1) |
if (shmctl((int)shmid, IPC_RMID, NULL) == -1) |
| 57 |
{ |
{ |
| 58 |
log_error("shmctl(shmid=%d, IPC_RMID) error (%d)\n", (int)shmid, errno); |
log_error("shmctl(shmid=%d, IPC_RMID) error (%d)\n", (int)shmid, errno); |
| 68 |
|
|
| 69 |
trie_dict_traverse(p_trie_file_dict, trie_file_dict_cleanup_cb); |
trie_dict_traverse(p_trie_file_dict, trie_file_dict_cleanup_cb); |
| 70 |
trie_dict_destroy(p_trie_file_dict); |
trie_dict_destroy(p_trie_file_dict); |
|
p_trie_file_dict = NULL; |
|
| 71 |
} |
} |
| 72 |
|
|
| 73 |
int load_file_shm(const char *filename) |
int load_file_shm(const char *filename) |