Merge "Explicit cast from android::Base::Errno to status_t"
This commit is contained in:
@@ -1585,7 +1585,7 @@ static jobject nativeCreateInputChannel(JNIEnv* env, jclass /* clazz */, jlong p
|
|||||||
|
|
||||||
if (!inputChannel.ok()) {
|
if (!inputChannel.ok()) {
|
||||||
std::string message = inputChannel.error().message();
|
std::string message = inputChannel.error().message();
|
||||||
message += StringPrintf(" Status=%d", inputChannel.error().code());
|
message += StringPrintf(" Status=%d", static_cast<int>(inputChannel.error().code()));
|
||||||
jniThrowRuntimeException(env, message.c_str());
|
jniThrowRuntimeException(env, message.c_str());
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
@@ -1619,7 +1619,7 @@ static jobject nativeCreateInputMonitor(JNIEnv* env, jclass /* clazz */, jlong p
|
|||||||
|
|
||||||
if (!inputChannel.ok()) {
|
if (!inputChannel.ok()) {
|
||||||
std::string message = inputChannel.error().message();
|
std::string message = inputChannel.error().message();
|
||||||
message += StringPrintf(" Status=%d", inputChannel.error().code());
|
message += StringPrintf(" Status=%d", static_cast<int>(inputChannel.error().code()));
|
||||||
jniThrowRuntimeException(env, message.c_str());
|
jniThrowRuntimeException(env, message.c_str());
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user