mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 15:38:40 +01:00
nfs-kernel-server: fix segfault on x86_64/uClibc
Signed-off-by: W. Michael Petullo <mike@flyn.org> [refresh patch] Signed-off-by: Etienne CHAMPETIER <champetier.etienne@gmail.com>
This commit is contained in:
committed by
Etienne CHAMPETIER
parent
d33b2c7ef9
commit
df9eb01b4d
@@ -0,0 +1,20 @@
|
||||
--- a/support/export/hostname.c
|
||||
+++ b/support/export/hostname.c
|
||||
@@ -350,7 +350,9 @@ host_numeric_addrinfo(const struct socka
|
||||
|
||||
/*
|
||||
* getaddrinfo(AI_NUMERICHOST) never fills in ai_canonname
|
||||
+ * ...well, it does on uclibc.
|
||||
*/
|
||||
+#ifndef __UCLIBC__
|
||||
if (ai != NULL) {
|
||||
free(ai->ai_canonname); /* just in case */
|
||||
ai->ai_canonname = strdup(buf);
|
||||
@@ -359,6 +361,7 @@ host_numeric_addrinfo(const struct socka
|
||||
ai = NULL;
|
||||
}
|
||||
}
|
||||
+#endif
|
||||
|
||||
return ai;
|
||||
}
|
||||
Reference in New Issue
Block a user