Merge "Fix JNI leak in copyStringToBuffer Bug: 5244396"
This commit is contained in:
@@ -352,7 +352,6 @@ LOG_WINDOW("Copying string for %d,%d from %p", row, column, window);
|
|||||||
char buf[32];
|
char buf[32];
|
||||||
int len;
|
int len;
|
||||||
snprintf(buf, sizeof(buf), "%lld", value);
|
snprintf(buf, sizeof(buf), "%lld", value);
|
||||||
jchar* dst = env->GetCharArrayElements(buffer, NULL);
|
|
||||||
sizeCopied = charToJchar(buf, dst, bufferSize);
|
sizeCopied = charToJchar(buf, dst, bufferSize);
|
||||||
}
|
}
|
||||||
} else if (type == FIELD_TYPE_FLOAT) {
|
} else if (type == FIELD_TYPE_FLOAT) {
|
||||||
@@ -360,7 +359,6 @@ LOG_WINDOW("Copying string for %d,%d from %p", row, column, window);
|
|||||||
if (window->getDouble(row, column, &value)) {
|
if (window->getDouble(row, column, &value)) {
|
||||||
char tempbuf[32];
|
char tempbuf[32];
|
||||||
snprintf(tempbuf, sizeof(tempbuf), "%g", value);
|
snprintf(tempbuf, sizeof(tempbuf), "%g", value);
|
||||||
jchar* dst = env->GetCharArrayElements(buffer, NULL);
|
|
||||||
sizeCopied = charToJchar(tempbuf, dst, bufferSize);
|
sizeCopied = charToJchar(tempbuf, dst, bufferSize);
|
||||||
}
|
}
|
||||||
} else if (type == FIELD_TYPE_NULL) {
|
} else if (type == FIELD_TYPE_NULL) {
|
||||||
|
|||||||
Reference in New Issue
Block a user