mirror of
https://github.com/corda/corda.git
synced 2025-02-05 10:39:13 +00:00
return null from NewString[UTF] if the char* parameter is null
This commit is contained in:
parent
3862128a3a
commit
c711ac5701
@ -195,6 +195,8 @@ GetArrayLength(Thread* t, jarray array)
|
||||
jstring JNICALL
|
||||
NewString(Thread* t, const jchar* chars, jsize size)
|
||||
{
|
||||
if (chars == 0) return 0;
|
||||
|
||||
ENTER(t, Thread::ActiveState);
|
||||
|
||||
object a = 0;
|
||||
@ -210,6 +212,8 @@ NewString(Thread* t, const jchar* chars, jsize size)
|
||||
jstring JNICALL
|
||||
NewStringUTF(Thread* t, const char* chars)
|
||||
{
|
||||
if (chars == 0) return 0;
|
||||
|
||||
ENTER(t, Thread::ActiveState);
|
||||
|
||||
object a = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user