[qdbm-users] dpopen
Brought to you by:
mikio
|
From: George N. <ge...@ne...> - 2008-10-05 04:54:55
|
Hi All,
I am a new user of qdbm, I think there may be a bug in depot.c:255,
dpopen() (from v.1.8.77)
if(!(omode & DP_ONOLCK) &&
((dpbigendian() ? memcmp(hbuf, DP_MAGICNUMB, strlen(DP_MAGICNUMB)) != 0 :
memcmp(hbuf, DP_MAGICNUML, strlen(DP_MAGICNUML)) != 0) ||
*((int *)(hbuf + DP_FSIZOFF)) != fsiz)){
close(fd);
dpecodeset(DP_EBROKEN, __FILE__, __LINE__);
return NULL;
}
It seems to me these checks should -not- be qualified with !(omode &
DP_ONOLCK)
Is this a bug or intended?
Thanks,
George.
|