Bug 1688120 - Remove UB due to unnecessary integer conversion r=peterv

Differential Revision: https://phabricator.services.mozilla.com/D106577
This commit is contained in:
Paul Bone 2021-03-01 01:16:36 +00:00
Родитель 412e4af403
Коммит 017a947912
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -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);
}