Commit f2e8f390 authored by chrfranke's avatar chrfranke
Browse files

smartd: Fix directive '-l selftest' (ticket #36).

git-svn-id: https://smartmontools.svn.sourceforge.net/svnroot/smartmontools/trunk@3040 4ea69e1a-61f1-4043-bf83-b5c94c648137
parent f7270e02
...@@ -43,6 +43,9 @@ NOTES FOR FUTURE RELEASES: see TODO file. ...@@ -43,6 +43,9 @@ NOTES FOR FUTURE RELEASES: see TODO file.
<DEVELOPERS: ADDITIONS TO THE CHANGE LOG GO JUST BELOW HERE, PLEASE> <DEVELOPERS: ADDITIONS TO THE CHANGE LOG GO JUST BELOW HERE, PLEASE>
[CF] smartd: Fix directive '-l selftest' (ticket #36)
Regression was introduced with r2773.
[CF] smartd: Don't disable attribute tracking if read thresholds fails. [CF] smartd: Don't disable attribute tracking if read thresholds fails.
Windows: Don't return dummy thresholds if IOCTL_STORAGE_QUERY_PROPERTY Windows: Don't return dummy thresholds if IOCTL_STORAGE_QUERY_PROPERTY
or 3ware CLI is used to read SMART data. or 3ware CLI is used to read SMART data.
......
...@@ -13,6 +13,7 @@ Summary: smartmontools release 5.40 ...@@ -13,6 +13,7 @@ Summary: smartmontools release 5.40
- Drive database is in a separate source file 'drivedb.h' - Drive database is in a separate source file 'drivedb.h'
which can be downloaded from SVN. which can be downloaded from SVN.
- Fix regression in smartctl option '-q, --quietmode'. - Fix regression in smartctl option '-q, --quietmode'.
- Fix regression in smartd directive '-l selftest'.
Date 2009-12-09 Date 2009-12-09
Summary: smartmontools release 5.39 (UNSTABLE/EXPERIMENTAL) Summary: smartmontools release 5.39 (UNSTABLE/EXPERIMENTAL)
......
...@@ -2404,13 +2404,17 @@ int ataPrintSmartSelfTestlog(const ata_smart_selftestlog * data, bool allentries ...@@ -2404,13 +2404,17 @@ int ataPrintSmartSelfTestlog(const ata_smart_selftestlog * data, bool allentries
uint64_t lba48 = (log->lbafirstfailure < 0xffffffff ? log->lbafirstfailure : 0xffffffffffffULL); uint64_t lba48 = (log->lbafirstfailure < 0xffffffff ? log->lbafirstfailure : 0xffffffffffffULL);
// Print entry // Print entry
bool errorfound = ataPrintSmartSelfTestEntry(testno, if (ataPrintSmartSelfTestEntry(testno,
log->selftestnumber, log->selfteststatus, log->timestamp, log->selftestnumber, log->selfteststatus,
lba48, !allentries, noheaderprinted); log->timestamp, lba48, !allentries, noheaderprinted)) {
// Self-test showed an error
retval++;
// keep track of time of most recent error // keep track of time of most recent error
if (errorfound && !hours) if (!hours)
hours=log->timestamp; hours = log->timestamp;
}
} }
} }
if (!allentries && retval) if (!allentries && retval)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment