summaryrefslogtreecommitdiffstats
path: root/security/nss/lib/dbm
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@gmail.com>2018-04-25 21:33:33 +0200
committerwolfbeast <mcwerewolf@gmail.com>2018-04-25 21:33:33 +0200
commitfba28f19754f62b5227650143d5441fc86d4c7d7 (patch)
tree26629d73f83543ff92a060fd7b310bb748b13173 /security/nss/lib/dbm
parentb4154e043bfc0d2f301d88304efc896989d650bf (diff)
downloadUXP-fba28f19754f62b5227650143d5441fc86d4c7d7.tar
UXP-fba28f19754f62b5227650143d5441fc86d4c7d7.tar.gz
UXP-fba28f19754f62b5227650143d5441fc86d4c7d7.tar.lz
UXP-fba28f19754f62b5227650143d5441fc86d4c7d7.tar.xz
UXP-fba28f19754f62b5227650143d5441fc86d4c7d7.zip
Revert "Update NSS to 3.35-RTM"
This reverts commit f1a0f0a56fdd0fc39f255174ce08c06b91c66c94.
Diffstat (limited to 'security/nss/lib/dbm')
-rw-r--r--security/nss/lib/dbm/src/h_page.c15
-rw-r--r--security/nss/lib/dbm/src/hash.c3
2 files changed, 2 insertions, 16 deletions
diff --git a/security/nss/lib/dbm/src/h_page.c b/security/nss/lib/dbm/src/h_page.c
index e5623224b..bf1252aeb 100644
--- a/security/nss/lib/dbm/src/h_page.c
+++ b/security/nss/lib/dbm/src/h_page.c
@@ -426,9 +426,6 @@ ugly_split(HTAB *hashp, uint32 obucket, BUFHEAD *old_bufp,
last_bfp = NULL;
scopyto = (uint16)copyto; /* ANSI */
- if (ino[0] < 1) {
- return DATABASE_CORRUPTED_ERROR;
- }
n = ino[0] - 1;
while (n < ino[0]) {
@@ -466,13 +463,7 @@ ugly_split(HTAB *hashp, uint32 obucket, BUFHEAD *old_bufp,
* Fix up the old page -- the extra 2 are the fields
* which contained the overflow information.
*/
- if (ino[0] < (moved + 2)) {
- return DATABASE_CORRUPTED_ERROR;
- }
ino[0] -= (moved + 2);
- if (scopyto < sizeof(uint16) * (ino[0] + 3)) {
- return DATABASE_CORRUPTED_ERROR;
- }
FREESPACE(ino) =
scopyto - sizeof(uint16) * (ino[0] + 3);
OFFSET(ino) = scopyto;
@@ -495,14 +486,8 @@ ugly_split(HTAB *hashp, uint32 obucket, BUFHEAD *old_bufp,
for (n = 1; (n < ino[0]) && (ino[n + 1] >= REAL_KEY); n += 2) {
cino = (char *)ino;
key.data = (uint8 *)cino + ino[n];
- if (off < ino[n]) {
- return DATABASE_CORRUPTED_ERROR;
- }
key.size = off - ino[n];
val.data = (uint8 *)cino + ino[n + 1];
- if (ino[n] < ino[n + 1]) {
- return DATABASE_CORRUPTED_ERROR;
- }
val.size = ino[n] - ino[n + 1];
off = ino[n + 1];
diff --git a/security/nss/lib/dbm/src/hash.c b/security/nss/lib/dbm/src/hash.c
index 98b1c07c7..b80aad4d3 100644
--- a/security/nss/lib/dbm/src/hash.c
+++ b/security/nss/lib/dbm/src/hash.c
@@ -704,7 +704,8 @@ hash_put(
return (DBM_ERROR);
}
- rv = hash_access(hashp, flag == R_NOOVERWRITE ? HASH_PUTNEW : HASH_PUT,
+ rv = hash_access(hashp, flag == R_NOOVERWRITE ? HASH_PUTNEW
+ : HASH_PUT,
(DBT *)key, (DBT *)data);
if (rv == DATABASE_CORRUPTED_ERROR) {