|
Message-ID: <20031126175935.GA5456@openwall.com> Date: Wed, 26 Nov 2003 20:59:35 +0300 From: Solar Designer <solar@...nwall.com> To: owl-users@...ts.openwall.com Subject: Re: Bug in Postfix remove script On Wed, Nov 26, 2003 at 05:44:15PM +0100, Andreas Ericsson wrote: > > - rmdir /var/spool/postfix/[^m]* > > + rmdir /var/spool/postfix/[^m]* || true > This will cause rpm to happily move on no matter what the error, which > isn't the intended behaviour. Actually it is. The purpose of this rmdir is to remove directories which are empty, but leave around those which aren't such that you don't lose your queued e-mail messages just because you happened to (temporarily?) uninstall Postfix. If you install Postfix but don't use it and just uninstall, then everything gets removed cleanly. > - rmdir /var/spool/postfix/[^m]* > + find /var/spool/postfix \( -type d -name "[^m]*" \) -delete This is very different: find is recursive. A similar effect to the rmdir may be achieved with find -maxdepth 1, but I don't see the need. -- Alexander Peslyak <solar@...nwall.com> GPG key ID: B35D3598 fp: 6429 0D7E F130 C13E C929 6447 73C3 A290 B35D 3598 http://www.openwall.com - bringing security into open computing environments
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.