--- src/history.c.orig	Thu Apr  8 12:56:13 1999
+++ src/history.c	Sun Sep  9 14:00:33 2001
@@ -6,6 +6,12 @@
  *  the GNU General Public License applies
  *
  *  $Log: history.c,v $
+ *
+ *  Revision x.xx  2001/09/09
+ *  patch from G. Paul Ziemba to fix the return of dbzfetch
+ *  when inn is built with tagged-hash enabled
+ *  (applied by thierry@thomas.as).
+ *
  *  Revision 1.19  1999/04/08 10:56:13  src
  *  *** empty log message ***
  *
@@ -142,6 +148,9 @@
 	OFFSET_T offset;
 #  ifdef DO_TAGGED_HASH
 	offset = dbzfetch(key);
+	if (!offset) {	/* gpz 010907 start */
+		offset = -1;
+	}		/* gpz 010907 end */
 #  else
 	idxrec ionevalue;
 	idxrecext iextvalue;
@@ -161,6 +170,8 @@
 	    log_msg(L_DEBUGMORE,"msgid %s not in history",msgid);
 	    return 0;
 	}
+	log_msg(L_DEBUGMORE,"dbzver=6, msgid %s IS in history, off=%d",
+	    msgid, offset);
     }
     /* OK, we found it */
     return 1;
