From 3cdfaeca3fd18bb735bf386db51be88a26a7908b Mon Sep 17 00:00:00 2001 From: Adam Retter Date: Wed, 14 Dec 2016 10:17:52 -0800 Subject: [PATCH] Fixes for MSVC compilation Summary: Closes https://github.com/facebook/rocksdb/pull/1669 Differential Revision: D4327421 Pulled By: yiwu-arbug fbshipit-source-id: 661ee0b --- java/rocksjni/portal.h | 6 +++--- java/src/main/java/org/rocksdb/Status.java | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/java/rocksjni/portal.h b/java/rocksjni/portal.h index f51a0ba32..d075a1507 100644 --- a/java/rocksjni/portal.h +++ b/java/rocksjni/portal.h @@ -159,7 +159,7 @@ class StatusJni : public RocksDBNativeClass { case rocksdb::Status::Code::kTryAgain: return 0xD; default: - return 0xFF; // undefined + return 0x7F; // undefined } } @@ -176,9 +176,9 @@ class StatusJni : public RocksDBNativeClass { case rocksdb::Status::SubCode::kLockLimit: return 0x3; case rocksdb::Status::SubCode::kMaxSubCode: - return 0xFE; + return 0x7E; default: - return 0xFF; // undefined + return 0x7F; // undefined } } }; diff --git a/java/src/main/java/org/rocksdb/Status.java b/java/src/main/java/org/rocksdb/Status.java index 79d2e1321..b9ec348d6 100644 --- a/java/src/main/java/org/rocksdb/Status.java +++ b/java/src/main/java/org/rocksdb/Status.java @@ -92,7 +92,7 @@ public class Status { MutexTimeout( (byte)0x1), LockTimeout( (byte)0x2), LockLimit( (byte)0x3), - MaxSubCode( (byte)0xFE); + MaxSubCode( (byte)0x7E); private final byte value;