diff options
author | Michael McVady <femtonaut@gmail.com> | 2024-01-12 18:14:25 -0600 |
---|---|---|
committer | Michael McVady <femtonaut@gmail.com> | 2024-01-12 18:14:25 -0600 |
commit | df6e8b001a334c944bb53f0e31575afba4c28e65 (patch) | |
tree | a71d5c37e6c16cd42f4d89a17fa0770bc5ed2110 | |
parent | 85a1f20681b4f28b7e5230ef64c2b59e178ce638 (diff) |
Fix multiple search terms
-rw-r--r-- | src/clog.c | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -79,6 +79,8 @@ static void process_md_output(const MD_CHAR *html, MD_SIZE size, void *buf); static int render_md(const char *in, struct kore_buf *out); void entry_query_init(struct entry_query *eq, const char *id, const char *query) { + int i = 0; + if (id != NULL) { eq->id = kore_strdup(id); } @@ -88,6 +90,11 @@ void entry_query_init(struct entry_query *eq, const char *id, const char *query) if (query != NULL) { eq->query = kore_strdup(query); + for (i = 0; i < strlen(eq->query); ++i) { + if (eq->query[i] == ' ') { + eq->query[i] = '|'; + } + } } else { eq->query = NULL; |