diff options
author | Michael McVady <femtonaut@gmail.com> | 2024-01-13 14:24:03 -0600 |
---|---|---|
committer | Michael McVady <femtonaut@gmail.com> | 2024-01-13 14:24:03 -0600 |
commit | 5a3489865fa7efe40eaa59a4ca865387b25f0d35 (patch) | |
tree | c5f99ab56b5d27da93e8df1a6b5c8fb8ae9b7ba3 /src/clog.c | |
parent | 5830cf2890bc01efa16f76c971408a8ffd76bd1d (diff) |
lint whitespace
Diffstat (limited to 'src/clog.c')
-rw-r--r-- | src/clog.c | 24 |
1 files changed, 12 insertions, 12 deletions
@@ -83,7 +83,7 @@ void entry_query_init(struct entry_query *eq, const char *id, const char *query) if (id != NULL) { eq->id = kore_strdup(id); - } + } else { eq->id = NULL; } @@ -96,7 +96,7 @@ void entry_query_init(struct entry_query *eq, const char *id, const char *query) eq->query[i] = '|'; } } - } + } else { eq->query = NULL; } @@ -115,7 +115,7 @@ void entry_query_cleanup(struct entry_query *eq) { kore_free((void *) eq->id); } eq->id = NULL; - + if (eq->query != NULL) { kore_free((void *) eq->query); } @@ -247,11 +247,11 @@ int get_index(struct http_request *req) { // Write table footer. kore_buf_append(content, asset_table_footer_html, asset_len_table_footer_html); - + http_ok_resp(req, HTTP_STATUS_OK, content); - + out: ; - + kore_free(content); entry_query_cleanup(&eq); @@ -309,7 +309,7 @@ int get_entry(struct http_request *req) { out: ; entry_query_cleanup(&eq); - + kore_free(rendered_body); kore_free(content); @@ -330,7 +330,7 @@ int edit_entry(struct http_request *req) { id = kore_strdup(req->path + strlen("/entries/")); id[strlen(id) - strlen("/edit")] = '\0'; - + entry_query_init(&eq, (const char*) id, NULL); // Check for valid resource UUID @@ -390,7 +390,7 @@ int update_entry(struct http_request *req) { char *id = NULL; char *title = NULL; char *body = NULL; - + http_populate_post(req); if (http_argument_get_string(req, "title", &title)) { @@ -493,11 +493,11 @@ int search_entries(struct http_request *req) { } http_ok_resp(req, HTTP_STATUS_OK, content); - + out: ; entry_query_cleanup(&eq); - + kore_free(content); return KORE_RESULT_OK; @@ -645,7 +645,7 @@ static int render_md(const char *in, struct kore_buf *out) { static unsigned parser_flags = 0; static unsigned renderer_flags = 0; - + parser_flags |= MD_FLAG_TABLES; parser_flags |= MD_FLAG_STRIKETHROUGH; // parser_flags |= MD_FLAG_TASKLISTS; |