summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--utils.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/utils.h b/utils.h
index 7e277c8..e773dea 100644
--- a/utils.h
+++ b/utils.h
@@ -237,7 +237,7 @@ uInformation(const char * /* s */ , ...
);
#endif
#ifdef HAVE_STRDUP
-#define uStringDup(s1) (strdup(s1))
+#define uStringDup(s1) ((s1) ? strdup(s1) : NULL)
#else
extern char *uStringDup(const char * /* s1 */
);