move temp file removal before possible exit point
[debian/sudo] / debian / sudo.postinst
index 33fd3d1d457dc2c188b61b80d2c17b1d809a68bb..3d40784d54e238b8b2aca20c41a05c899259612c 100644 (file)
@@ -26,6 +26,9 @@ system ('update-rc.d -f sudo remove >/dev/null 2>&1');
 
 system ('update-rc.d sudo start 75 2 3 4 5 . >/dev/null');
 
+# if we've gotten this far .. remove the saved, unchanged old sudoers file
+system ('rm -f /etc/sudoers.pre-conffile');
+
 # make sure we have a sudo group
 
 exit 0 if getgrnam("sudo"); # we're finished if there is a group sudo