зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1688120 - Remove UB due to unnecessary integer conversion r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D106577
This commit is contained in:
Родитель
412e4af403
Коммит
017a947912
|
@ -338,7 +338,7 @@ already_AddRefed<XPCNativeInterface> XPCNativeInterface::NewInstance(
|
|||
|
||||
// Use placement new to create an object with the right amount of space
|
||||
// to hold the members array
|
||||
int size = sizeof(XPCNativeInterface);
|
||||
size_t size = sizeof(XPCNativeInterface);
|
||||
if (realTotalCount > 1) {
|
||||
size += (realTotalCount - 1) * sizeof(XPCNativeMember);
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче