summaryrefslogtreecommitdiff
path: root/src/util.c
diff options
context:
space:
mode:
authorportix <portix@gmx.net>2010-12-22 12:52:31 +0100
committerportix <portix@gmx.net>2010-12-22 12:52:31 +0100
commitee1f3776310676fd6ef0f48cdc6ca077b02faace (patch)
treef6bff2bedd4ccee4d66a0aa32a346fbccec8b1f2 /src/util.c
parent68a00da9bd9b0b59aafcdf1141dbf6dac5c7aa48 (diff)
downloaddwb-ee1f3776310676fd6ef0f48cdc6ca077b02faace.zip
allow empty strings in adblock
Diffstat (limited to 'src/util.c')
-rw-r--r--src/util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/util.c b/src/util.c
index 45abef3e..550ed657 100644
--- a/src/util.c
+++ b/src/util.c
@@ -403,7 +403,7 @@ dwb_true() {
/* dwb_return(const char *) return char * (alloc) {{{*/
char *
dwb_return(const char *ret) {
- return g_strdup(ret);
+ return ret && strlen(ret) > 0 ? g_strdup(ret) : NULL;
}/*}}}*/
/* dwb_malloc(size_t size) return: void* {{{*/