]> tinc-vpn.org Git - tinc/blobdiff - src/xmalloc.c
Fix compatibility with TAP-Win32 9.0.0.21 and later.
[tinc] / src / xmalloc.c
index 1e4001738aca3b59a2408759d23a199607019c12..39dc03c7229d79d7d321781ba78283fd1ea4f59e 100644 (file)
@@ -113,6 +113,9 @@ char *xstrdup(const char *s)
 {
   char *p;
   
+  if(!s)
+    return NULL;
+
   p = strdup(s);
   if(!p)
     xalloc_fail ((int)strlen(s));