| 141 | } |
| 142 | |
| 143 | static void UpdateFree(OpBase *ctx) { |
| 144 | OpUpdate *op = (OpUpdate *)ctx; |
| 145 | |
| 146 | if(op->node_updates) { |
| 147 | HashTableRelease(op->node_updates); |
| 148 | op->node_updates = NULL; |
| 149 | } |
| 150 | |
| 151 | if(op->edge_updates) { |
| 152 | HashTableRelease(op->edge_updates); |
| 153 | op->edge_updates = NULL; |
| 154 | } |
| 155 | |
| 156 | // free each update context |
| 157 | if(op->update_ctxs) { |
| 158 | raxFreeWithCallback(op->update_ctxs, (void(*)(void *))UpdateCtx_Free); |
| 159 | op->update_ctxs = NULL; |
| 160 | } |
| 161 | |
| 162 | if(op->records) { |
| 163 | uint records_count = array_len(op->records); |
| 164 | for(uint i = 0; i < records_count; i++) OpBase_DeleteRecord(op->records[i]); |
| 165 | array_free(op->records); |
| 166 | op->records = NULL; |
| 167 | } |
| 168 | |
| 169 | raxStop(&op->it); |
| 170 | } |
nothing calls this directly
no test coverage detected