diff --git a/toolkit/components/osfile/NativeOSFileInternals.cpp b/toolkit/components/osfile/NativeOSFileInternals.cpp index a674df14e10d..9d54a4f696df 100644 --- a/toolkit/components/osfile/NativeOSFileInternals.cpp +++ b/toolkit/components/osfile/NativeOSFileInternals.cpp @@ -114,7 +114,7 @@ struct ScopedArrayBufferContents: public Scoped bool Allocate(uint32_t length) { dispose(); ArrayBufferContents& value = rwget(); - void *ptr = calloc(1, length); + void *ptr = js_calloc(1, length); if (ptr) { value.data = (uint8_t *) ptr; value.nbytes = length;