Kaydet (Commit) 723719b4 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Silence -Werror=nonnull (GCC 6)

Change-Id: I3aa5f4342ad362b0075d033df222467723ee002e
üst 011ce226
...@@ -123,7 +123,15 @@ int __lxstat(int n, const char *path, struct stat *buf) ...@@ -123,7 +123,15 @@ int __lxstat(int n, const char *path, struct stat *buf)
p_lstat = (int (*)(int n, const char *path, struct stat *buf)) p_lstat = (int (*)(int n, const char *path, struct stat *buf))
dlsym (RTLD_NEXT, "__lxstat"); dlsym (RTLD_NEXT, "__lxstat");
ret = (*p_lstat)(n, path, buf); ret = (*p_lstat)(n, path, buf);
#if defined __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wnonnull"
// __lxstat may be declared in system headers as taking nonnull argument
#endif
assert(buf != NULL); assert(buf != NULL);
#if defined __GNUC__
#pragma GCC diagnostic pop
#endif
buf->st_uid = 0; /* root */ buf->st_uid = 0; /* root */
buf->st_gid = 0; /* root */ buf->st_gid = 0; /* root */
return ret; return ret;
......
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