소스 검색

Mutex instrumentation for troubleshooting...

git-svn-id: http://svn.code.sf.net/p/itop/code/trunk@3595 a333f486-631f-4898-b8df-5754b55c2be0
dflaven 10 년 전
부모
커밋
2ea54b8644
1개의 변경된 파일5개의 추가작업 그리고 1개의 파일을 삭제
  1. 5 1
      core/mutex.class.inc.php

+ 5 - 1
core/mutex.class.inc.php

@@ -131,7 +131,11 @@ class iTopMutex
 			$this->bLocked = true;
 			self::$aAcquiredLocks[$this->sName]++;
 		}
-		return ($res === '1');
+		if (($res !== '1') && ($res !== '0'))
+		{
+			IssueLog::Error('GET_LOCK('.$this->sName.', 0) returned: '.var_export($res, true).'. Expected values are: 0, 1 or null !!');
+		}
+		return ($res !== '0');
 	}
 
 	/**