If we're going to assert that logData != NULL, do it before we

try to dereference logData.

Reported by:	"Ted Unangst" <tedu@coverity.com>
Approved by:	rwatson (mentor), scottl
This commit is contained in:
Colin Percival 2004-02-22 01:08:33 +00:00
parent 8d4fdfaf45
commit bff4678e78

View File

@ -690,9 +690,9 @@ rf_ParityLogAppend(
*
* NON-BLOCKING */
RF_ASSERT(logData != NULL);
raidPtr = logData->common->raidPtr;
/* lock the region for the first item in logData */
RF_ASSERT(logData != NULL);
regionID = logData->regionID;
RF_LOCK_MUTEX(raidPtr->regionInfo[regionID].mutex);
RF_ASSERT(raidPtr->regionInfo[regionID].loggingEnabled);