mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1081601: Stop copying arrays manually. r=rnewman
This commit is contained in:
parent
2ae96ad3f6
commit
76954ef20a
@ -247,9 +247,7 @@ public class ContactService implements GeckoEventListener {
|
|||||||
// Truncate the raw contacts IDs array if necessary
|
// Truncate the raw contacts IDs array if necessary
|
||||||
if (filterLimit > 0 && allRawContactIds.length > filterLimit) {
|
if (filterLimit > 0 && allRawContactIds.length > filterLimit) {
|
||||||
long[] truncatedRawContactIds = new long[filterLimit];
|
long[] truncatedRawContactIds = new long[filterLimit];
|
||||||
for (int i = 0; i < filterLimit; i++) {
|
System.arraycopy(allRawContactIds, 0, truncatedRawContactIds, 0, filterLimit);
|
||||||
truncatedRawContactIds[i] = allRawContactIds[i];
|
|
||||||
}
|
|
||||||
return truncatedRawContactIds;
|
return truncatedRawContactIds;
|
||||||
}
|
}
|
||||||
return allRawContactIds;
|
return allRawContactIds;
|
||||||
|
Loading…
Reference in New Issue
Block a user