From: Karl DeBisschop Date: Fri, 18 Oct 2002 04:41:05 +0000 (+0000) Subject: handle null src in strscat X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=c8d2aa6221dfc20e76e263cde513beeba88f6d46;p=nagiosplug.git handle null src in strscat git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@140 f882894a-f735-0410-b71e-b25c423dba1c --- diff --git a/plugins/utils.c b/plugins/utils.c index 0d1729e..697b5a6 100644 --- a/plugins/utils.c +++ b/plugins/utils.c @@ -416,6 +416,8 @@ char * strscat (char *dest, const char *src) { + if (dest == NULL) + return src; if (src != NULL) asprintf (&dest, "%s%s", dest, src);