From 25cba03d2dac565fab667884bf711439f9a70544 Mon Sep 17 00:00:00 2001 From: Christian Perrier Date: Wed, 16 Apr 2014 06:27:01 +0200 Subject: [PATCH] Fix 1000_configure_userns to avoid dropping a needed #endif Closes: #744877 --- debian/changelog | 4 ++++ debian/patches/1000_configure_userns | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 4d6e6973..58b7f04c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -47,6 +47,10 @@ shadow (1:4.2-1) UNRELEASED; urgency=low * Switch to dpkg-source 3.0 (quilt) format * Add build-dependency against bison * Call dh-autoreconf since we need to regenerate all the autofoo files + + [ Philippe Grégoire ] + * Fix 1000_configure_userns to avoid dropping a needed #endif + Closes: #744877 -- Christian Perrier Sat, 27 Jul 2013 20:07:18 +0200 diff --git a/debian/patches/1000_configure_userns b/debian/patches/1000_configure_userns index 0cddc99d..5cd39b61 100644 --- a/debian/patches/1000_configure_userns +++ b/debian/patches/1000_configure_userns @@ -51,17 +51,17 @@ Index: git/src/useradd.c /* * Get my name so that I can use it to report errors. */ -@@ -2023,9 +2027,10 @@ +@@ -2023,8 +2027,10 @@ is_shadow_grp = sgr_file_present (); #endif #ifdef ENABLE_SUBIDS - is_sub_uid = sub_uid_file_present (); - is_sub_gid = sub_gid_file_present (); --#endif /* ENABLE_SUBIDS */ + is_sub_uid = sub_uid_file_present () && !rflg && + (!user_id || (user_id <= uid_max && user_id >= uid_min)); + is_sub_gid = sub_gid_file_present () && !rflg && + (!user_id || (user_id <= uid_max && user_id >= uid_min)); + #endif /* ENABLE_SUBIDS */ get_defaults ();