aboutsummaryrefslogtreecommitdiff
path: root/src/hashtable.h
diff options
context:
space:
mode:
authorkoekeishiya <aasvi93@hotmail.com>2019-02-23 14:49:56 +0100
committerkoekeishiya <aasvi93@hotmail.com>2019-02-23 14:49:56 +0100
commit0e703c3f275f6d4477f452acfb9cf9c73b9d9f1e (patch)
tree6d46a0835b6614548ac9292067e8b3b4590e134f /src/hashtable.h
parenteeab7a37a2e017ea36d2385fd6b03b9572f181aa (diff)
downloadskhd-0e703c3f275f6d4477f452acfb9cf9c73b9d9f1e.tar.gz
skhd-0e703c3f275f6d4477f452acfb9cf9c73b9d9f1e.zip
#59 reload config when input source changes
Diffstat (limited to 'src/hashtable.h')
-rw-r--r--src/hashtable.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/hashtable.h b/src/hashtable.h
index 42d0166..f593432 100644
--- a/src/hashtable.h
+++ b/src/hashtable.h
@@ -76,7 +76,10 @@ void table_free(struct table *table)
bucket = next;
}
}
- free(table->buckets);
+ if (table->buckets) {
+ free(table->buckets);
+ table->buckets = NULL;
+ }
}
void *table_find(struct table *table, void *key)