search for: 270f81a4

Displaying 2 results from an estimated 2 matches for "270f81a4".

2020 Sep 03
0
[PATCH nbdkit] server/public.c: Uninline nbdkit_strdup_intern to avoid compiler warning.
...ceeds maximum object size 9223372036854775807 [-Werror=stringop-overflow=] 827 | copy = strndup (str, n); | ^~~~~~~~~~~~~~~~ --- server/public.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/server/public.c b/server/public.c index e871fdeb..270f81a4 100644 --- a/server/public.c +++ b/server/public.c @@ -836,7 +836,21 @@ nbdkit_strndup_intern (const char *str, size_t n) const char * nbdkit_strdup_intern (const char *str) { - return nbdkit_strndup_intern (str, SIZE_MAX); + char *copy; + + if (str == NULL) { + nbdkit_error ("nbdkit_...
2020 Sep 03
4
[PATCH nbdkit] server/public.c: Uninline nbdkit_strdup_intern to avoid compiler warning.
I'm not sure if this is a GCC bug or a bug in our code, but the attached workaround fixes it for me. Rich.