Commit ed3e9519 authored by Jeff Walden's avatar Jeff Walden
Browse files

Bug 1443342 - Blacklist nsZipArchive.cpp's entry-name hashing function from...

Bug 1443342 - Blacklist nsZipArchive.cpp's entry-name hashing function from being checked for unsigned integer overflows, because it knowingly relies on them.  r=froydnj

--HG--
extra : rebase_source : f71e49bcb679b1c3d3a1a8e48f2d6bffd320e876
parent ba597518
Loading
Loading
Loading
Loading
+0 −3
Original line number Diff line number Diff line
@@ -253,9 +253,6 @@ fun:*_hash_mix_bits*
fun:*_cairo_hash_string*
fun:*_cairo_hash_bytes*

# Hash function in modules/libjar/nsZipArchive.cpp
fun:*HashName*

# intl code hashing functions
fun:*ustr_hash*CharsN*
fun:*hashEntry*
+0 −3
Original line number Diff line number Diff line
@@ -260,9 +260,6 @@ fun:*_hash_mix_bits*
fun:*_cairo_hash_string*
fun:*_cairo_hash_bytes*

# Hash function in modules/libjar/nsZipArchive.cpp
fun:*HashName*

# intl code hashing functions
fun:*ustr_hash*CharsN*
fun:*hashEntry*
+2 −0
Original line number Diff line number Diff line
@@ -18,6 +18,7 @@
#include "nsISupportsUtils.h"
#include "prio.h"
#include "plstr.h"
#include "mozilla/Attributes.h"
#include "mozilla/Logging.h"
#include "mozilla/UniquePtrExtensions.h"
#include "stdlib.h"
@@ -964,6 +965,7 @@ nsZipFind::~nsZipFind()
 *
 * returns a hash key for the entry name
 */
MOZ_NO_SANITIZE_UNSIGNED_OVERFLOW
static uint32_t HashName(const char* aName, uint16_t len)
{
  MOZ_ASSERT(aName != 0);