1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-21 04:06:46 +00:00

Avoid junk pointer when __db_vrfy_datapage() fails

Rather than second-guessing what the __os_free() might be doing and
avoiding it, initialize the pointer to NULL, which __os_free() will
skip.  This should be the safer approach if Oracle ever patches other
parts of db 5.3.

PR:		210829
Submitted by:	Mark Millard
This commit is contained in:
Matthias Andree 2016-11-09 22:31:48 +00:00
parent 4365088e18
commit 7a68cdcef2
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=425813
4 changed files with 14 additions and 3 deletions

View File

@ -3,7 +3,7 @@
PORTNAME= db5
PORTVERSION= 5.3.28
PORTREVISION= 5
PORTREVISION= 6
CATEGORIES= databases java
MASTER_SITES= http://download.oracle.com/berkeley-db/
PKGNAMEPREFIX?=

View File

@ -1,4 +1,4 @@
--- lang/tcl/tcl_env.c.orig 2016-05-24 08:19:08 UTC
--- lang/tcl/tcl_env.c.orig 2013-09-09 15:35:07 UTC
+++ lang/tcl/tcl_env.c
@@ -2864,9 +2864,10 @@ env_GetFlags(interp, objc, objv, dbenv)
for (i = 0; open_flags[i].flag != 0; i++)

View File

@ -1,4 +1,4 @@
--- lang/tcl/tcl_seq.c.orig 2016-05-24 08:18:03 UTC
--- lang/tcl/tcl_seq.c.orig 2013-09-09 15:35:07 UTC
+++ lang/tcl/tcl_seq.c
@@ -555,9 +555,10 @@ tcl_SeqGetFlags(interp, objc, objv, seq)
for (i = 0; seq_flags[i].flag != 0; i++)

View File

@ -0,0 +1,11 @@
--- src/heap/heap_verify.c.orig 2013-09-09 15:35:08 UTC
+++ src/heap/heap_verify.c
@@ -122,7 +122,7 @@ __heap_vrfy(dbp, vdp, h, pgno, flags)
{
HEAPHDR *hdr;
int cnt, i, j, ret;
- db_indx_t *offsets, *offtbl, end;
+ db_indx_t *offsets = NULL, *offtbl, end;
if ((ret = __db_vrfy_datapage(dbp, vdp, h, pgno, flags)) != 0)
goto err;