Commit | Line | Data |
---|---|---|
1 | /* | |
2 | * misc.c: Miscellaneous helpful functions. | |
3 | */ | |
4 | ||
5 | #include <assert.h> | |
6 | #include <stdlib.h> | |
7 | ||
8 | #include "puzzles.h" | |
9 | ||
10 | void free_cfg(config_item *cfg) | |
11 | { | |
12 | config_item *i; | |
13 | ||
14 | for (i = cfg; i->type != C_END; i++) | |
15 | if (i->type == C_STRING) | |
16 | sfree(i->sval); | |
17 | sfree(cfg); | |
18 | } |