Updated dictionary. Implemented "compression" of dictionary.
[idzebra-moved-to-github.git] / index / extract.c
index d9c619b..0486bb6 100644 (file)
@@ -4,7 +4,13 @@
  * Sebastian Hammer, Adam Dickmeiss
  *
  * $Log: extract.c,v $
- * Revision 1.91  1999-02-12 13:29:22  adam
+ * Revision 1.93  1999-05-15 14:36:38  adam
+ * Updated dictionary. Implemented "compression" of dictionary.
+ *
+ * Revision 1.92  1999/03/09 16:27:49  adam
+ * More work on SDRKit integration.
+ *
+ * Revision 1.91  1999/02/12 13:29:22  adam
  * Implemented position-flag for registers.
  *
  * Revision 1.90  1999/02/02 14:50:52  adam
@@ -402,7 +408,7 @@ int key_open (struct recordGroup *rGroup, int mem)
     key_buf_used = 0;
     key_file_no = 0;
 
-    if (!(matchDict = dict_open (bfs, GMATCH_DICT, 50, rw)))
+    if (!(matchDict = dict_open (bfs, GMATCH_DICT, 50, rw, 0)))
     {
         logf (LOG_FATAL, "dict_open fail of %s", GMATCH_DICT);
        return -1;
@@ -1634,14 +1640,17 @@ int fileExtract (SYSNO *sysno, const char *fname,
         rGroup->flagStoreKeys = 0;
 
 #if ZEBRASDR
-    if (1)
+    if (rGroup->useSDR)
     {
        ZebraSdrHandle h;
        char xname[128], *xp;
 
        strncpy (xname, fname, 127);
-       if ((xp = strchr (xname, '.')))
-           *xp = '\0';
+       if (!(xp = strchr (xname, '.')))
+           return 0;
+       *xp = '\0';
+       if (strcmp (xp+1, "sdr.bits"))
+           return 0;
 
         h = zebraSdr_open (xname);
        if (!h)
@@ -1657,9 +1666,8 @@ int fileExtract (SYSNO *sysno, const char *fname,
 
            segmentno = zebraSdr_segment (h, 0);
            sprintf (sdr_name, "%%%s.%d", xname, segmentno);
-           logf (LOG_LOG, "SDR: %s", sdr_name);
 
-#if 1
+#if 0
            if (segmentno > 20)
                break;
 #endif