Unverified Commit 331ae3a2 by Stéphane Graber Committed by GitHub

Merge pull request #1981 from brauner/2017-12-01/fix_android_sethostname

utils: declare sethostname() static inline
parents 810c42ac 2650fb4d
...@@ -122,7 +122,7 @@ static inline int setns(int fd, int nstype) ...@@ -122,7 +122,7 @@ static inline int setns(int fd, int nstype)
/* Define sethostname() if missing from the C library */ /* Define sethostname() if missing from the C library */
#ifndef HAVE_SETHOSTNAME #ifndef HAVE_SETHOSTNAME
static int sethostname(const char * name, size_t len) static inline int sethostname(const char * name, size_t len)
{ {
#ifdef __NR_sethostname #ifdef __NR_sethostname
return syscall(__NR_sethostname, name, len); return syscall(__NR_sethostname, name, len);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment