NetBSD Problem Report #39254
From www@NetBSD.org Thu Jul 31 11:07:39 2008
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
by narn.NetBSD.org (Postfix) with ESMTP id 658F363B9AA
for <gnats-bugs@gnats.netbsd.org>; Thu, 31 Jul 2008 11:07:39 +0000 (UTC)
Message-Id: <20080731110739.2BDAA63B99A@narn.NetBSD.org>
Date: Thu, 31 Jul 2008 11:07:39 +0000 (UTC)
From: netbsd@mavetju.org
Reply-To: netbsd@mavetju.org
To: gnats-bugs@NetBSD.org
Subject: db(1) doesn't work properly anymore since the upgrade to 1.15
X-Send-Pr-Version: www-1.0
>Number: 39254
>Category: bin
>Synopsis: db(1) doesn't work properly anymore since the upgrade to 1.15
>Confidential: no
>Severity: serious
>Priority: low
>Responsible: bin-bug-people
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Jul 31 11:10:00 +0000 2008
>Closed-Date: Mon Aug 05 00:34:17 +0000 2024
>Last-Modified: Mon Aug 05 00:34:17 +0000 2024
>Originator: Edwin Groothuis
>Release: 4.0
>Organization:
-
>Environment:
>Description:
With the commit of revision 1.15, the db(1) command is broken when selecting a single key:
$ db/db -N hash hash.db localhost
db: Error reading key `localhost': Invalid argument
The invalid argument comes from hash_seq() in src/lib/libc/db/hash/hash.c, which checks for the flags being R_FIRST or R_NEXT. db_get() calls it with R_CURSOR, which works fine for a BTree database but not for hash-database.
>How-To-Repeat:
>Fix:
Backout of 1.14.
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed
State-Changed-By: riastradh@NetBSD.org
State-Changed-When: Mon, 05 Aug 2024 00:34:17 +0000
State-Changed-Why:
fixed by lukem@ in rev. 1.24 of src/usr.bin/db/db.c back in 2009
>Unformatted:
(Contact us)
$NetBSD: gnats-precook-prs,v 1.4 2018/12/21 14:20:20 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.