소스 검색

Fix SafeNumeric::conditional_increment() for NO_THREADS

(cherry picked from commit b1edb69249928d385f462543f3e0fa69d3037d2a)
Pedro J. Estébanez 4 년 전
부모
커밋
5a67eefbcf
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      core/safe_refcount.h

+ 1 - 1
core/safe_refcount.h

@@ -249,7 +249,7 @@ public:
 	}
 
 	_ALWAYS_INLINE_ T conditional_increment() {
-		if (value != 0) {
+		if (value == 0) {
 			return 0;
 		} else {
 			return ++value;