summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew G. Morgan <morgan@kernel.org>2001-09-13 02:31:39 +0000
committerAndrew G. Morgan <morgan@kernel.org>2001-09-13 02:31:39 +0000
commit03d37947ca0f5436d4a0bef27bd50f19acbfe16c (patch)
tree772f3a625d9ff1368073a867fee0c2702e15e607
parentcdf8300ff2ddee6a71e3318a5083fa4209e747a9 (diff)
Relevant BUGIDs: 461089
Purpose of commit: cleanup Commit summary: --------------- remove a compilation warning.
-rw-r--r--CHANGELOG1
-rw-r--r--modules/pam_unix/pam_unix_passwd.c9
2 files changed, 9 insertions, 1 deletions
diff --git a/CHANGELOG b/CHANGELOG
index 091a7387..d243742f 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -49,6 +49,7 @@ bug report - outstanding bugs are listed here:
0.76: please submit patches for this section with actual code/doc
patches!
+* pam_unix_passwd: got rid of an annoying warning (Bug 461089 - agmorgan)
* pam_unix: removed superfluous use of static variables in md5 and bigcrypt
routines, bringing us a step closer to thread-safeness. Eliminated
some variable indirection along the way. (Bug 440107 - vorlon)
diff --git a/modules/pam_unix/pam_unix_passwd.c b/modules/pam_unix/pam_unix_passwd.c
index 85c0a44d..7f8f6e03 100644
--- a/modules/pam_unix/pam_unix_passwd.c
+++ b/modules/pam_unix/pam_unix_passwd.c
@@ -350,7 +350,14 @@ static int _update_passwd(const char *forwho, const char *towhat)
tmpent = fgetpwent(opwfile);
while (tmpent) {
if (!strcmp(tmpent->pw_name, forwho)) {
- tmpent->pw_passwd = towhat;
+ /* To shut gcc up */
+ union {
+ const char *const_charp;
+ char *charp;
+ } assigned_passwd;
+ assigned_passwd.const_charp = towhat;
+
+ tmpent->pw_passwd = assigned_passwd.charp;
}
if (putpwent(tmpent, pwfile)) {
fprintf(stderr, "error writing entry to password file: %s\n",