about summary refs log tree commit diff stats
path: root/src/common.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/common.c')
-rw-r--r--src/common.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/common.c b/src/common.c
index fc701b8b..0a314c91 100644
--- a/src/common.c
+++ b/src/common.c
@@ -195,6 +195,12 @@ str_replace(const char *string, const char *substr,
 gboolean
 str_contains_str(const char *  const searchstr, const char * const substr)
 {
+    if (!searchstr) {
+        return FALSE;
+    }
+    if (!substr) {
+        return FALSE;
+    }
     return g_strrstr(searchstr, substr) != NULL;
 }