Set things to a sane state for db(3) routines.
This commit is contained in:
parent
35b8613acb
commit
be1f1ece47
|
@ -1,8 +1,8 @@
|
|||
/* $NetBSD: pkgdb.c,v 1.4 1999/08/24 00:48:40 hubertf Exp $ */
|
||||
/* $NetBSD: pkgdb.c,v 1.5 1999/12/20 18:23:03 hubertf Exp $ */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#ifndef lint
|
||||
__RCSID("$NetBSD: pkgdb.c,v 1.4 1999/08/24 00:48:40 hubertf Exp $");
|
||||
__RCSID("$NetBSD: pkgdb.c,v 1.5 1999/12/20 18:23:03 hubertf Exp $");
|
||||
#endif
|
||||
|
||||
/*
|
||||
|
@ -131,6 +131,8 @@ pkgdb_retrieve(const char *key)
|
|||
keyd.size = strlen(key) + 1;
|
||||
errno = 0; /* to be sure it's 0 if the key doesn't match anything */
|
||||
|
||||
vald.data = (void *)NULL;
|
||||
vald.size = 0;
|
||||
status = (pkgdbp->get) (pkgdbp, &keyd, &vald, 0);
|
||||
if (status) {
|
||||
vald.data = NULL;
|
||||
|
|
Loading…
Reference in New Issue