diff options
author | Jeremy Huddleston <jeremyhu@apple.com> | 2012-05-19 04:30:49 -0700 |
---|---|---|
committer | Jeremy Huddleston <jeremyhu@apple.com> | 2012-05-19 04:30:49 -0700 |
commit | 641588afe92c803a1231ecf6281115f55b20e62a (patch) | |
tree | a5a80c4f0bd73c058a797a6b03eb32210630c14a /launchd/privileged_startx | |
parent | 335937217a51e5e159a14463e0b1e3aedf35c6be (diff) |
laucnhd: Silence some syslog spam
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
Diffstat (limited to 'launchd/privileged_startx')
-rwxr-xr-x | launchd/privileged_startx/10-tmpdirs.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/launchd/privileged_startx/10-tmpdirs.cpp b/launchd/privileged_startx/10-tmpdirs.cpp index 7786426..6ba045f 100755 --- a/launchd/privileged_startx/10-tmpdirs.cpp +++ b/launchd/privileged_startx/10-tmpdirs.cpp @@ -41,14 +41,14 @@ STAT=/usr/bin/stat for dir in /tmp/.ICE-unix /tmp/.X11-unix /tmp/.font-unix ; do success=0 for attempt in 1 2 3 4 5 ; do - check=`${STAT} -f '%#p %u %g' ${dir}` + check=`${STAT} -f '%#p %u %g' ${dir} 2> /dev/null` if [ "${check}" = "041777 0 0" ] ; then success=1 break - else + elif [ -n "${check}" ] ; then saved=$(${MKTEMP} -d ${dir}-XXXXXXXX) mv ${dir} ${saved} - echo "${dir} exists but is insecure. It has been moved into ${saved}" + echo "${dir} exists but is insecure. It has been moved into ${saved}" >&2 fi # Use mktemp rather than mkdir to avoid possible security issue |