mirror of
https://github.com/corda/corda.git
synced 2025-06-04 08:30:52 +00:00
Merge pull request #477 from dicej/getEntryBytes
do not null-terminate ZipEntry names in openjdk-src builds
This commit is contained in:
commit
cbfce38aa1
@ -1658,9 +1658,8 @@ int64_t JNICALL
|
||||
switch (type) {
|
||||
case 0: { // name
|
||||
unsigned nameLength = fileNameLength(entry->start);
|
||||
GcByteArray* array = makeByteArray(t, nameLength + 1);
|
||||
GcByteArray* array = makeByteArray(t, nameLength);
|
||||
memcpy(array->body().begin(), fileName(entry->start), nameLength);
|
||||
array->body()[nameLength] = 0;
|
||||
return reinterpret_cast<int64_t>(array);
|
||||
} break;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user