Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 211243 Details for
Bug 294709
Enhance sys-apps/openrc-0.5.2-r2 to skip wiping tmpfs-mounted dirs
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Adds function is_dir_tmpfs and calls to it in two spots
openrc-0.5.2-skip-wiping-tmpfs-dirs.patch (text/plain), 1.89 KB, created by
Raffaello D. Di Napoli
on 2009-11-26 11:48:10 UTC
(
hide
)
Description:
Adds function is_dir_tmpfs and calls to it in two spots
Filename:
MIME Type:
Creator:
Raffaello D. Di Napoli
Created:
2009-11-26 11:48:10 UTC
Size:
1.89 KB
patch
obsolete
>--- openrc-0.5.2/init.d/bootmisc.in 2009-11-26 12:03:39.311907098 +0100 >+++ openrc-0.5.2/init.d/bootmisc.in 2009-11-26 12:10:07.554903556 +0100 >@@ -16,6 +16,11 @@ > mkdir "$1"/.test.$$ 2>/dev/null && rmdir "$1"/.test.$$ > } > >+is_dir_tmpfs() >+{ >+ [ -e "$1" ] && [ $(stat -fc%T "$1") = tmpfs ] >+} >+ > : ${wipe_tmp:=${WIPE_TMP:-yes}} > > cleanup_tmp_dir() >@@ -98,36 +103,38 @@ > [ -e /var/log/wtmp ] || mkutmp /var/log/wtmp > eend 0 > >- ebegin "Cleaning /var/run" >- for x in $(find /var/run ! -type d ! -name utmp \ >- ! -name random-seed ! -name dev.db \ >- ! -name ld-elf.so.hints ! -name ld.so.hints); >- do >- # Clean stale sockets >- if [ -S "$x" ]; then >- if type fuser >/dev/null 2>&1; then >- fuser "$x" >/dev/null 2>&1 || rm -- "$x" >- else >- rm -- "$x" >+ if ! is_dir_tmpfs /var/run; then >+ ebegin "Cleaning /var/run" >+ for x in $(find /var/run ! -type d ! -name utmp \ >+ ! -name random-seed ! -name dev.db \ >+ ! -name ld-elf.so.hints ! -name ld.so.hints); >+ do >+ # Clean stale sockets >+ if [ -S "$x" ]; then >+ if type fuser >/dev/null 2>&1; then >+ fuser "$x" >/dev/null 2>&1 || rm -- "$x" >+ else >+ rm -- "$x" >+ fi > fi >- fi >- [ ! -f "$x" ] && continue >- # Do not remove pidfiles of already running daemons >- case "$x" in >- *.pid) >- start-stop-daemon --test --quiet \ >- --stop --pidfile "$x" && continue >- ;; >- esac >- rm -f -- "$x" >- done >- eend 0 >+ [ ! -f "$x" ] && continue >+ # Do not remove pidfiles of already running daemons >+ case "$x" in >+ *.pid) >+ start-stop-daemon --test --quiet \ >+ --stop --pidfile "$x" && continue >+ ;; >+ esac >+ rm -f -- "$x" >+ done >+ eend 0 >+ fi > fi > > # Clean up /tmp directories > local tmp= > for tmp in ${clean_tmp_dirs:-${wipe_tmp_dirs-/tmp}}; do >- cleanup_tmp_dir "$tmp" >+ ! is_dir_tmpfs "$tmp" && cleanup_tmp_dir "$tmp" > done > > if dir_writeable /tmp; then
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 294709
: 211243