diff --git a/debian/changelog b/debian/changelog index 2e93b35a..c3340407 100644 --- a/debian/changelog +++ b/debian/changelog @@ -5,6 +5,7 @@ shadow (1:4.1.2-1) experimental; urgency=low - Updated patches: + debian/patches/431_su_uid_0_not_root + debian/patches/463_login_delay_obeys_to_PAM + + debian/patches/579_chowntty_debug * debian/control: changed the "Replaces" on manpages-zh to a versioned one on 1.5.1-1 * debian/control: drop all Replaces on manpages-* when the version is diff --git a/debian/patches/579_chowntty_debug b/debian/patches/579_chowntty_debug index 5b4e9f6f..2844e18b 100644 --- a/debian/patches/579_chowntty_debug +++ b/debian/patches/579_chowntty_debug @@ -25,26 +25,26 @@ Index: shadow-4.1.0/libmisc/chowntty.c /* * is_my_tty -- determine if "tty" is the same as TTY stdin is using */ -@@ -47,12 +48,31 @@ +@@ -47,13 +48,31 @@ { struct stat by_name, by_fd; -- if (stat (tty, &by_name) || fstat (0, &by_fd)) -+ if (stat (tty, &by_name)) { +- if ((stat (tty, &by_name) != 0) || (fstat (0, &by_fd) != 0)) { ++ if (stat (tty, &by_name) != 0) { + /* Can use neither strerror() nor "%m" sequence -- first + * is locale-dependent (while SYSLOG isn't) and for second + * the SYSLOG macro isn't errno-transparent. --xrgtn */ + int e = errno; + SYSLOG ((LOG_WARN, "can't stat(`%s'): errno %i\n", tty, e)); - return 0; -+ } + return false; + } -- if (by_name.st_rdev != by_fd.st_rdev) -+ if (fstat (0, &by_fd)) { +- if (by_name.st_rdev != by_fd.st_rdev) { ++ if (fstat (0, &by_fd) != 0) { + int e = errno; + SYSLOG ((LOG_WARN, "can't fstat(stdin): errno %i\n", e)); - return 0; -- else + return false; +- } else { + } + + if (by_name.st_rdev != by_fd.st_rdev) { @@ -55,8 +55,8 @@ Index: shadow-4.1.0/libmisc/chowntty.c + * which are GNU extn */ + major(by_name.st_rdev), minor(by_name.st_rdev), + major(by_fd.st_rdev), minor(by_fd.st_rdev))); -+ return 0; -+ } else - return 1; ++ return false; ++ } else { + return true; + } } -