From 1ca0a2515416a37acdf0adde8e051fc09edd480b Mon Sep 17 00:00:00 2001 From: Jean Delvare Date: Mon, 2 Jun 2008 06:23:51 +0000 Subject: [PATCH] Don't use named pipes when we don't need them. Named pipes have been reported to cause trouble on some systems. This closes ticket #2319. git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@5272 7894878c-1315-0410-8ee3-d5d059ff63e0 --- CHANGES | 1 + prog/pwm/fancontrol | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/CHANGES b/CHANGES index 3b0e561f..5533ef35 100644 --- a/CHANGES +++ b/CHANGES @@ -12,6 +12,7 @@ SVN-HEAD Module i2c-sis5595: Minor cleanups (2.6 backport) Module lm75: Fix an incorrect comment (2.6 backport) Module w83l785ts: Don't ask user to report failures (2.6 backport) + Program fancontrol: Don't use named pipes when we don't need them (#2319) Program sensord: Add lm90, adm1032, lm99, lm86, max6657, adt7461 support Program sensors-detect: New device ID for the SMSC SCH5317 Add SMSC SCH5127 detection diff --git a/prog/pwm/fancontrol b/prog/pwm/fancontrol index b479b5a1..15c084ef 100755 --- a/prog/pwm/fancontrol +++ b/prog/pwm/fancontrol @@ -338,7 +338,8 @@ function UpdateFanSpeeds { then # if fan was stopped start it using a safe value echo $minsa > $pwmo # Sleep while still handling signals - read < <(exec sleep 1) + sleep 1 & + wait $! fi fi echo $pwmval > $pwmo # write new value to pwm output @@ -376,5 +377,6 @@ while true do UpdateFanSpeeds # Sleep while still handling signals - read < <(exec sleep $INTERVAL) + sleep $INTERVAL & + wait $! done