FS-11911: Fix build on Debian Buster

This commit is contained in:
Andrey Volk committed 2019-07-15 22:23:25 +04:00
1 parent 4f50a24a90
commit a7477ed0e2
24 files changed
+36 -50

No files matched your search

@@ -34,6 +34,7 @@
#include "config.h"
#include <string.h>
#include <stdio.h>
#include "sofia-sip/su_alloc.h"
/** Duplicate a string, allocate memory from @a home.
@@ -54,7 +55,7 @@ char *su_strdup(su_home_t *home, char const *s)
size_t n = strlen(s);
char *retval = su_alloc(home, n + 1);
if (retval)
strncpy(retval, s, n)[n] = 0;
snprintf(retval, n + 1, "%s", s);
return retval;
}
return NULL;