FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > ArchLinux > ArchLinux General Discussion

 
 
LinkBack Thread Tools
 
Old 06-30-2010, 09:47 PM
Victor Lowther
 
Default find has a builtin delete action. Use it instead of exec'ing rm.

---
rc.sysinit | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/rc.sysinit b/rc.sysinit
index 319ea60..037a9f2 100755
--- a/rc.sysinit
+++ b/rc.sysinit
@@ -277,7 +277,7 @@ stat_busy "Removing Leftover Files"
/bin/rm -f /var/lock/* &>/dev/null
/bin/rm -rf /tmp/* /tmp/.* &>/dev/null
/bin/rm -f /forcefsck &>/dev/null
-(cd /var/run && /usr/bin/find . ! -type d -exec /bin/rm -f -- {} ; )
+(cd /var/run && /usr/bin/find . ! -type d -delete )
: >| /var/run/utmp
/bin/chmod 0664 /var/run/utmp
# Keep {x,k,g}dm happy with xorg
--
1.7.1
 
Old 07-16-2010, 12:00 PM
Thomas Bächler
 
Default find has a builtin delete action. Use it instead of exec'ing rm.

Am 30.06.2010 23:47, schrieb Victor Lowther:
> ---
> rc.sysinit | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/rc.sysinit b/rc.sysinit
> index 319ea60..037a9f2 100755
> --- a/rc.sysinit
> +++ b/rc.sysinit
> @@ -277,7 +277,7 @@ stat_busy "Removing Leftover Files"
> /bin/rm -f /var/lock/* &>/dev/null
> /bin/rm -rf /tmp/* /tmp/.* &>/dev/null
> /bin/rm -f /forcefsck &>/dev/null
> -(cd /var/run && /usr/bin/find . ! -type d -exec /bin/rm -f -- {} ; )
> +(cd /var/run && /usr/bin/find . ! -type d -delete )
> : >| /var/run/utmp
> /bin/chmod 0664 /var/run/utmp
> # Keep {x,k,g}dm happy with xorg

ACKed.
 

Thread Tools




All times are GMT. The time now is 04:36 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org