summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Hawthorn <john.hawthorn@gmail.com>2016-05-02 21:45:26 -0700
committerJohn Hawthorn <john.hawthorn@gmail.com>2016-05-02 21:45:26 -0700
commitaed59e60a2b54589bcd173dd263a882b8f9a0b64 (patch)
tree6d1bc67291e8e1ad912ec17ef7eb7e7b2c57b783
parentc5ab36831ec13a695e35de627409929eff05ff46 (diff)
Rename choices_free to choices_destroy
To clarify that we aren't freeing the choices structure, just the buffers associated with it.
-rw-r--r--choices.c2
-rw-r--r--choices.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/choices.c b/choices.c
index 2513db1..99b0d99 100644
--- a/choices.c
+++ b/choices.c
@@ -97,7 +97,7 @@ void choices_init(choices_t *c) {
choices_reset_search(c);
}
-void choices_free(choices_t *c) {
+void choices_destroy(choices_t *c) {
free(c->buffer);
c->buffer = NULL;
c->buffer_size = 0;
diff --git a/choices.h b/choices.h
index 63468ab..d8d547c 100644
--- a/choices.h
+++ b/choices.h
@@ -24,7 +24,7 @@ typedef struct {
void choices_init(choices_t *c);
void choices_fread(choices_t *c, FILE *file);
-void choices_free(choices_t *c);
+void choices_destroy(choices_t *c);
void choices_add(choices_t *c, const char *choice);
size_t choices_available(choices_t *c);
void choices_search(choices_t *c, const char *search);