mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-26 02:42:58 +02:00
Merge branch 'next'
This commit is contained in:
@@ -8,7 +8,7 @@ case "$1" in
|
||||
start)
|
||||
boot_mesg -n "Enabling S.M.A.R.T.: ";
|
||||
for disk in `kudzu -qps -c HD | grep device: | cut -d" " -f2 | sort | uniq`; do
|
||||
/usr/sbin/smartctl -d ata --smart=on /dev/$disk > /dev/nul;
|
||||
/usr/sbin/smartctl --smart=on /dev/$disk > /dev/nul;
|
||||
if [ ${?} = 0 ]; then
|
||||
boot_mesg -n "$SUCCESS$disk$NORMAL ";
|
||||
else
|
||||
|
||||
@@ -36,7 +36,7 @@ int main(int argc, char *argv[]) {
|
||||
exit(1);
|
||||
}
|
||||
|
||||
sprintf(command, "smartctl -iHA -d ata /dev/%s", argv[1]);
|
||||
sprintf(command, "smartctl -iHA /dev/%s", argv[1]);
|
||||
safe_system(command);
|
||||
|
||||
return 0;
|
||||
|
||||
16
src/patches/smartmontools-5.39-error_throw_int.patch
Normal file
16
src/patches/smartmontools-5.39-error_throw_int.patch
Normal file
@@ -0,0 +1,16 @@
|
||||
diff -Naur smartmontools-5.39-svn_r2877/utility.h smartmontools-5.39-svn_r2877.new/utility.h
|
||||
--- smartmontools-5.39-svn_r2877/utility.h 2009-08-24 12:48:50.000000000 +0200
|
||||
+++ smartmontools-5.39-svn_r2877.new/utility.h 2009-08-29 09:11:07.000000000 +0200
|
||||
@@ -102,7 +102,11 @@
|
||||
|
||||
// Replacement for exit(status)
|
||||
// (exit is not compatible with C++ destructors)
|
||||
-#define EXIT(status) { throw (int)(status); }
|
||||
+
|
||||
+//This doesn't work on IPFire.
|
||||
+//#define EXIT(status) { throw (int)(status); }
|
||||
+//tried to use exit and found no problems yet
|
||||
+#define EXIT(status) { exit ((int)(status)); }
|
||||
|
||||
|
||||
#ifdef OLD_INTERFACE
|
||||
@@ -83,7 +83,7 @@ sub updatehdddata{
|
||||
if (!$standby){
|
||||
$temp = 0;
|
||||
my $smart_output = '';
|
||||
system("$path_smartctl -iHA -d ata /dev/$disk > /var/run/smartctl_out_hddtemp-$disk");
|
||||
system("$path_smartctl -iHA /dev/$disk > /var/run/smartctl_out_hddtemp-$disk");
|
||||
if ( -e "/var/run/smartctl_out_hddtemp-".$array[$#array] ){
|
||||
my $hdd_output = `cat /var/run/smartctl_out_hddtemp-$array[$#array] | grep Temperature_`;
|
||||
my @t = split(/\s+/,$hdd_output);
|
||||
|
||||
Reference in New Issue
Block a user