Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

v47i124: ddb - dynamic memory database library, Patch05

3 views
Skip to first unread message

Christopher Phillips

unread,
Apr 12, 1995, 3:00:00 AM4/12/95
to
Submitted-by: Christophe...@pe.utexas.edu (Christopher Phillips)
Posting-number: Volume 47, Issue 124
Archive-name: ddb/patch05
Environment: ANSI-C
Patch-To: ddb: Volume 40, Issue 82

This is patch05 for ddb, a library of dynamic memory database routines.

There are a few changes:

- A memory leak in bfree() has been fixed.
- <sys/types.h> is no longer #included. ddb.h now #includes <stddef.h>

Just cd to the source directory and unshar this file. Then type

patch -p0 < Patch05

Chris
Christophe...@pe.utexas.edu
-----------
#! /bin/sh
# This is a shell archive. Remove anything before this line, then unpack
# it by saving it into a file and typing "sh file". To overwrite existing
# files, type "sh file -c". You can also feed this as standard input via
# unshar, or by typing "sh <file", e.g.. If this archive is complete, you
# will see the following message at the end:
# "End of shell archive."
# Contents: Patch05
# Wrapped by pef...@spica.cc.utexas.edu on Mon Apr 10 14:13:44 1995
PATH=/bin:/usr/bin:/usr/ucb ; export PATH
if test -f 'Patch05' -a "${1}" != "-c" ; then
echo shar: Will not clobber existing file \"'Patch05'\"
else
echo shar: Extracting \"'Patch05'\" \(2691 characters\)
sed "s/^X//" >'Patch05' <<'END_OF_FILE'
X*** ../ddb.old/binary.c Mon Apr 10 14:04:11 1995
X--- binary.c Mon Apr 10 14:12:30 1995
X***************
X*** 20,26 ****
X #include <stdio.h>
X #include <stdlib.h>
X #include <string.h>
X- #include <sys/types.h>
X #include <errno.h>
X #include "ddb.h"
X
X--- 20,25 ----
X***************
X*** 135,148 ****
X static void
X bfree(BELEM *bp)
X {
X- BELEM *right;
X-
X if (bp) {
X bfree(bp->left);
X- right = bp->right;
X free(bp->key.addr);
X free(bp->data.addr);
X! bfree(right);
X }
X }
X
X--- 134,145 ----
X static void
X bfree(BELEM *bp)
X {
X if (bp) {
X bfree(bp->left);
X free(bp->key.addr);
X free(bp->data.addr);
X! bfree(bp->right);
X! free(bp);
X }
X }
X
X*** ../ddb.old/bit.c Mon Apr 10 14:04:11 1995
X--- bit.c Mon Apr 10 14:12:33 1995
X***************
X*** 19,25 ****
X #include <stdlib.h>
X #include <string.h>
X #include <limits.h>
X- #include <sys/types.h>
X #include <errno.h>
X #include "ddb.h"
X
X--- 19,24 ----
X*** ../ddb.old/ddb.h Mon Apr 10 14:04:11 1995
X--- ddb.h Mon Apr 10 14:12:44 1995
X***************
X*** 18,24 ****
X #ifndef H_DDB
X #define H_DDB
X
X! #include <sys/types.h>
X
X typedef struct {
X void *addr;
X--- 18,24 ----
X #ifndef H_DDB
X #define H_DDB
X
X! #include <stddef.h>
X
X typedef struct {
X void *addr;
X*** ../ddb.old/hash.c Mon Apr 10 14:04:11 1995
X--- hash.c Mon Apr 10 14:12:47 1995
X***************
X*** 18,24 ****
X #include <stdio.h>
X #include <stdlib.h>
X #include <string.h>
X- #include <sys/types.h>
X #include <errno.h>
X #include "ddb.h"
X
X--- 18,23 ----
X*** ../ddb.old/list.c Mon Apr 10 14:04:11 1995
X--- list.c Mon Apr 10 14:12:50 1995
X***************
X*** 18,24 ****
X #include <stdio.h>
X #include <stdlib.h>
X #include <string.h>
X- #include <sys/types.h>
X #include <errno.h>
X #include "ddb.h"
X
X--- 18,23 ----
X*** ../ddb.old/new.c Mon Apr 10 14:04:11 1995
X--- new.c Mon Apr 10 14:12:54 1995
X***************
X*** 17,23 ****
X
X #include <stdio.h>
X #include <stdlib.h>
X- #include <sys/types.h>
X #include <string.h>
X #include "ddb.h"
X
X--- 17,22 ----
X*** ../ddb.old/patchlevel.h Mon Apr 10 14:04:11 1995
X--- patchlevel.h Mon Apr 10 14:10:45 1995
X***************
X*** 1 ****
X! #define PATCHLEVEL 4
X--- 1 ----
X! #define PATCHLEVEL 5
X*** ../ddb.old/queue.c Mon Apr 10 14:04:11 1995
X--- queue.c Mon Apr 10 14:12:59 1995
X***************
X*** 17,23 ****
X
X #include <stdio.h>
X #include <stdlib.h>
X- #include <sys/types.h>
X #include <errno.h>
X #include "ddb.h"
X
X--- 17,22 ----
X*** ../ddb.old/stack.c Mon Apr 10 14:04:11 1995
X--- stack.c Mon Apr 10 14:13:02 1995
X***************
X*** 17,23 ****
X
X #include <stdio.h>
X #include <stdlib.h>
X- #include <sys/types.h>
X #include <errno.h>
X #include "ddb.h"
X
X--- 17,22 ----
END_OF_FILE
if test 2691 -ne `wc -c <'Patch05'`; then
echo shar: \"'Patch05'\" unpacked with wrong size!
fi
# end of 'Patch05'
fi
echo shar: End of shell archive.
exit 0

exit 0 # Just in case...

0 new messages