Browse code

domain: fix use after free on domain reload

MancaČ™ George authored on 16/04/2021 16:26:35 • GitHub committed on 16/04/2021 16:26:35
Showing 1 changed files
... ...
@@ -204,8 +204,9 @@ void hash_table_free(struct domain_list **hash_table)
204 204
 			shm_free(ap);
205 205
 			ap = next_ap;
206 206
 		}
207
+		next = np->next;
207 208
 		shm_free(np);
208
-		np = np->next;
209
+		np = next;
209 210
 	}
210 211
 
211 212
 	hash_table[DOM_HASH_SIZE] = NULL;