Commit 4a40128e authored by Jeff Trull's avatar Jeff Trull

clean up narrowing conversion warnings in x86_64

parent 1dc5a248
......@@ -230,7 +230,7 @@ namespace djinni
// Using .data() on an empty vector is UB
if(!c.empty())
{
jniEnv->SetByteArrayRegion(j.get(), 0, c.size(), reinterpret_cast<const jbyte*>(c.data()));
jniEnv->SetByteArrayRegion(j.get(), 0, jsize(c.size()), reinterpret_cast<const jbyte*>(c.data()));
}
return j;
}
......
......@@ -366,7 +366,7 @@ jstring jniStringFromUTF8(JNIEnv * env, const std::string & str) {
utf16_encode(utf8_decode(str, i), utf16);
jstring res = env->NewString(
reinterpret_cast<const jchar *>(utf16.data()), utf16.length());
reinterpret_cast<const jchar *>(utf16.data()), jsize(utf16.length()));
DJINNI_ASSERT(res, env);
return res;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment