dbm/ndbm notes and some code.

George Robbins grr at cbmvax.UUCP
Fri May 12 19:06:34 AEST 1989


In article <1889 at yunexus.UUCP> oz at yunexus.UUCP (Ozan Yigit) writes:
> During my development of sdbm, a ndbm/dbm substitute (soon to beta: do not
> send mail), I have found one bug that has gone unnoticed on probably most
> of ndbm/dbm implementations.  One can write a simple workaround to this,
> but a bug is a bug nevertheless.  Remember that line from the man page: 
... 
> This is where the "database traversal" turns into a pumpkin.  Because of
> internal caching of the key position for dbm_nextkey (dbm_keyptr ??),
> which is appearently NOT adjusted for deletions, this traversal will never
> display the key right after the one just deleted. Workaround is to save
> all keys to be deleted, then perform all deletions once the sequential
> traversal is complete.

Say what?  Where are you going to save this potentially unbounded list of
to be deleted keys?  Surely there is a better solution???

-- 
George Robbins - now working for,	uucp: {uunet|pyramid|rutgers}!cbmvax!grr
but no way officially representing	arpa: cbmvax!grr at uunet.uu.net
Commodore, Engineering Department	fone: 215-431-9255 (only by moonlite)



More information about the Comp.lang.c mailing list