Fixes for MSVC compilation

Summary: Closes https://github.com/facebook/rocksdb/pull/1669

Differential Revision: D4327421

Pulled By: yiwu-arbug

fbshipit-source-id: 661ee0b
main
Adam Retter 8 years ago committed by Facebook Github Bot
parent e097222e64
commit 3cdfaeca3f
  1. 6
      java/rocksjni/portal.h
  2. 2
      java/src/main/java/org/rocksdb/Status.java

@ -159,7 +159,7 @@ class StatusJni : public RocksDBNativeClass<rocksdb::Status*, StatusJni> {
case rocksdb::Status::Code::kTryAgain:
return 0xD;
default:
return 0xFF; // undefined
return 0x7F; // undefined
}
}
@ -176,9 +176,9 @@ class StatusJni : public RocksDBNativeClass<rocksdb::Status*, StatusJni> {
case rocksdb::Status::SubCode::kLockLimit:
return 0x3;
case rocksdb::Status::SubCode::kMaxSubCode:
return 0xFE;
return 0x7E;
default:
return 0xFF; // undefined
return 0x7F; // undefined
}
}
};

@ -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;

Loading…
Cancel
Save