diff options
author | portix <portix@gmx.net> | 2010-12-20 10:51:43 +0100 |
---|---|---|
committer | portix <portix@gmx.net> | 2010-12-20 10:51:43 +0100 |
commit | 5e89072999741699983cc1578643685bcb7b2c2c (patch) | |
tree | aef709ef58705962a26ef4fbd2a9290884f74f1e /src/util.c | |
parent | e0213b8ad8ffda102797cec0004203f4de9c281b (diff) | |
download | dwb-5e89072999741699983cc1578643685bcb7b2c2c.zip |
added mail-program property
Diffstat (limited to 'src/util.c')
-rw-r--r-- | src/util.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -14,7 +14,7 @@ char * dwb_util_string_replace(const char *haystack, const char *needle, const char *replacemant) { char **token; char *ret = NULL; - if ( (token = g_regex_split_simple(needle, haystack, 0, 0)) && strcmp(token[0], haystack)) { + if ( haystack && needle && (token = g_regex_split_simple(needle, haystack, 0, 0)) && strcmp(token[0], haystack)) { ret = g_strconcat(token[0], replacemant, token[1], NULL); g_strfreev(token); } |