summaryrefslogtreecommitdiff
path: root/eel
diff options
context:
space:
mode:
Diffstat (limited to 'eel')
-rw-r--r--eel/eel-string.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/eel/eel-string.c b/eel/eel-string.c
index 3c3bc29e..f366e586 100644
--- a/eel/eel-string.c
+++ b/eel/eel-string.c
@@ -292,9 +292,10 @@ eel_str_replace_substring (const char *string,
{
return NULL;
}
- else if (replacement == NULL)
+
+ if (replacement == NULL)
{
- return (char *) string;
+ replacement = "";
}
substring_length = strlen (substring);