Merge "define pw_gecos to pw_passwd for LP32 systems" am: 9c212fc436
am: 52ce6c3bf4

* commit '52ce6c3bf4b4e2ec2c6cf69f5706bad98e9e6b75':
  define pw_gecos to pw_passwd for LP32 systems
diff --git a/libc/bionic/stubs.cpp b/libc/bionic/stubs.cpp
index 0340f0e..374d015 100644
--- a/libc/bionic/stubs.cpp
+++ b/libc/bionic/stubs.cpp
@@ -116,6 +116,7 @@
   snprintf(buf, byte_count, "%s%c%s%c%s", src->pw_name, 0, src->pw_dir, 0, src->pw_shell);
 
   // pw_passwd and pw_gecos are non-POSIX and unused (always NULL) in bionic.
+  // Note: On LP32, we define pw_gecos to pw_passwd since they're both NULL.
   dst->pw_passwd = NULL;
 #if defined(__LP64__)
   dst->pw_gecos = NULL;
diff --git a/libc/include/pwd.h b/libc/include/pwd.h
index 6012b96..905bc75 100644
--- a/libc/include/pwd.h
+++ b/libc/include/pwd.h
@@ -106,6 +106,9 @@
   gid_t pw_gid;
 #ifdef __LP64__
   char* pw_gecos;
+#else
+  // Note: On LP32, we define pw_gecos to pw_passwd since they're both NULL.
+# define pw_gecos pw_passwd
 #endif
   char* pw_dir;
   char* pw_shell;