about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--search.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/search.c b/search.c
index 2d6e417..07a8064 100644
--- a/search.c
+++ b/search.c
@@ -139,5 +139,13 @@ enum kcgi_err searchPage(struct kreq *req) {
 		if (error) return error;
 	}
 
+	if (!rows) {
+		error = 0
+			|| khtml_elem(&html, KELEM_TR)
+			|| khtml_elem(&html, KELEM_TH)
+			|| khtml_puts(&html, "No matching messages");
+		if (error) return error;
+	}
+
 	return htmlFooter(&html) || khtml_close(&html);
 }