| 113 | } |
| 114 | |
| 115 | static struct mem_pool *find_mem_pool(struct index_state *istate) |
| 116 | { |
| 117 | struct mem_pool **pool_ptr; |
| 118 | |
| 119 | if (istate->split_index && istate->split_index->base) |
| 120 | pool_ptr = &istate->split_index->base->ce_mem_pool; |
| 121 | else |
| 122 | pool_ptr = &istate->ce_mem_pool; |
| 123 | |
| 124 | if (!*pool_ptr) { |
| 125 | *pool_ptr = xmalloc(sizeof(**pool_ptr)); |
| 126 | mem_pool_init(*pool_ptr, 0); |
| 127 | } |
| 128 | |
| 129 | return *pool_ptr; |
| 130 | } |
| 131 | |
| 132 | static const char *alternate_index_output; |
| 133 |
no test coverage detected