Index: harvest/components/broker/standard/glimpse/index/build_in.c
diff -c harvest/components/broker/standard/glimpse/index/build_in.c:2.1 harvest/components/broker/standard/glimpse/index/build_in.c:2.2
*** harvest/components/broker/standard/glimpse/index/build_in.c:2.1	Thu Apr 17 10:40:41 1997
--- harvest/components/broker/standard/glimpse/index/build_in.c	Sun Oct 12 15:22:45 1997
***************
*** 948,955 ****
  			    next_record = forward_delimiter(buffer, buffer_end, rdelim, rdelim_len, 0);
  			}
  		    }
! 		    /* printf("%s\n", word); */
! 		    if(word[0] == '\0') continue;
  		    if(icount - hash_icount >= I_THRESHOLD) {
  #if	BG_DEBUG
  			fprintf(LOGFILE, "reached I_THRESHOLD at %d\n", icount - hash_icount);
--- 948,955 ----
  			    next_record = forward_delimiter(buffer, buffer_end, rdelim, rdelim_len, 0);
  			}
  		    }
! 		    if(word[0] == '\0' || attribute == -1) continue;
! 		    /*printf("%s\n", word);*/
  		    if(icount - hash_icount >= I_THRESHOLD) {
  #if	BG_DEBUG
  			fprintf(LOGFILE, "reached I_THRESHOLD at %d\n", icount - hash_icount);
***************
*** 960,966 ****
  		    }
  		    insert_h(word, i, attribute);
  		}
! 		if (word[0] != '\0') {
  		    /* printf("%s\n", word); */
  		    if(icount - hash_icount >= I_THRESHOLD) {
  #if	BG_DEBUG
--- 960,966 ----
  		    }
  		    insert_h(word, i, attribute);
  		}
! 		if (word[0] != '\0' && attribute != -1) {
  		    /* printf("%s\n", word); */
  		    if(icount - hash_icount >= I_THRESHOLD) {
  #if	BG_DEBUG
***************
*** 1154,1161 ****
  			    next_record = forward_delimiter(buffer, buffer_end, rdelim, rdelim_len, 0);
  			}
  		    }
  		    /* printf("%s\n", word); */
- 		    if(word[0] == '\0') continue;
  		    if(icount - hash_icount >= I_THRESHOLD) {
  #if	BG_DEBUG
  			fprintf(LOGFILE, "reached I_THRESHOLD at %d\n", icount - hash_icount);
--- 1154,1161 ----
  			    next_record = forward_delimiter(buffer, buffer_end, rdelim, rdelim_len, 0);
  			}
  		    }
+ 		    if(word[0] == '\0' || attribute == -1) continue;
  		    /* printf("%s\n", word); */
  		    if(icount - hash_icount >= I_THRESHOLD) {
  #if	BG_DEBUG
  			fprintf(LOGFILE, "reached I_THRESHOLD at %d\n", icount - hash_icount);
***************
*** 1166,1172 ****
  		    }
  		    insert_h(word, pn, attribute);
  		}
! 		if (word[0] != '\0') {
  		    /* printf("%s\n", word); */
  		    if(icount - hash_icount >= I_THRESHOLD) {
  #if	BG_DEBUG
--- 1166,1172 ----
  		    }
  		    insert_h(word, pn, attribute);
  		}
! 		if (word[0] != '\0' && attribute != -1) {
  		    /* printf("%s\n", word); */
  		    if(icount - hash_icount >= I_THRESHOLD) {
  #if	BG_DEBUG
Index: harvest/components/broker/standard/glimpse/index/glimpse.h
diff -c harvest/components/broker/standard/glimpse/index/glimpse.h:2.0 harvest/components/broker/standard/glimpse/index/glimpse.h:2.1
*** harvest/components/broker/standard/glimpse/index/glimpse.h:2.0	Sun Mar 16 16:59:41 1997
--- harvest/components/broker/standard/glimpse/index/glimpse.h	Sun Oct 12 15:22:47 1997
***************
*** 175,181 ****
  #define GLIMPSE_URL	"http://glimpse.cs.arizona.edu/"
  
  /* Some extern functions used in structured queries */
! extern int attr_name_to_id(), attr_load_names(), attr_dump_names();
  extern char *attr_id_to_name();
  
  /* Data structures for hash-tables in build_in.c */
--- 175,182 ----
  #define GLIMPSE_URL	"http://glimpse.cs.arizona.edu/"
  
  /* Some extern functions used in structured queries */
! extern int attr_name_to_id(), attr_load_names(), attr_dump_names(),
! 	   attr_ignore_name();
  extern char *attr_id_to_name();
  
  /* Data structures for hash-tables in build_in.c */
Index: harvest/components/broker/standard/glimpse/index/region.c
diff -c harvest/components/broker/standard/glimpse/index/region.c:2.0 harvest/components/broker/standard/glimpse/index/region.c:2.1
*** harvest/components/broker/standard/glimpse/index/region.c:2.0	Sun Mar 16 16:59:50 1997
--- harvest/components/broker/standard/glimpse/index/region.c	Sun Oct 12 15:22:48 1997
***************
*** 13,18 ****
--- 13,19 ----
  int attr_dump_names(/* char *filename */);
  int attr_load_names(/* char *filename */);
  int attr_free_table(/* void */);
+ int attr_ignore_name(/* char *name, int len */);
  int region_initialize(/* void */);
  int region_destroy(/* void */);
  int region_create(/* char *filename */);
***************
*** 137,142 ****
--- 138,166 ----
  	return e->attributeid;
  }
  
+ int
+ attr_ignore_name(name, len)
+ 	char	*name;
+ 	int	len;
+ {
+ 	int		index = attr_hash_index(name, len);
+ 	attr_element_t	**pe = &attr_hash_table[index], *e;
+ 
+ 	while(*pe != NULL) {
+ 		if (!strcmp((*pe)->attribute, name)) break;
+ 		else pe = &(*pe)->next;
+ 	}
+ 	if (*pe!=NULL) return (*pe)->attributeid;
+ 
+ 	e = (attr_element_t *)my_malloc(sizeof(attr_element_t));
+ 	e->attribute = (char *)my_malloc(len + 2);
+ 	strncpy(e->attribute, name, len + 1);
+ 	e->attributeid = -1;
+ 	e->next = NULL;
+ 	*pe = e;
+ 	return e->attributeid;
+ }
+ 
  /*
   * frees current hash table of attr-value pairs.
   * called after dump in indexing, and at end of search (after previous load).
***************
*** 487,511 ****
  	while (rl!=NULL) {
  		if (rl->offset > offset + len)
  			goto backwards;			/* definitely before: can be earlier region OR hole */
! 		else if ((rl->offset <= offset) && (rl->offset + rl->length >= offset + len))
  			return rl->attributeid;		/* definitely within */
  		else if (rl->offset + rl->length < offset)
  			nextpos = rl = rl->next;	/* definitely after: later region */
! 		else return 0;				/* overlapping: error */
  	}
! 	return 0;					/* reached end of file */
  
  backwards:
  	while (rl!=NULL) {
  		if (rl->offset > offset + len)
  			nextpos = rl = rl->prev;	/* definitely before: earlier region */
! 		else if ((rl->offset <= offset) && (rl->length + rl->length >= offset + len))
  			return rl->attributeid;		/* definitely within */
  		else if (rl->offset + rl->length < offset)
! 			return 0;			/* hole */
! 		else return 0;				/* overlapping: error */
  	}
! 	return 0;					/* reached end of file */
  }
  
  #else	/*STRUCTURED_QUERIES*/
--- 511,535 ----
  	while (rl!=NULL) {
  		if (rl->offset > offset + len)
  			goto backwards;			/* definitely before: can be earlier region OR hole */
! 		else if ((rl->offset <= offset) && (rl->offset + rl->length >= offset + len)) 
  			return rl->attributeid;		/* definitely within */
  		else if (rl->offset + rl->length < offset)
  			nextpos = rl = rl->next;	/* definitely after: later region */
! 		else return -1;				/* overlapping: error */
  	}
! 	return -1;					/* reached end of file */
  
  backwards:
  	while (rl!=NULL) {
  		if (rl->offset > offset + len)
  			nextpos = rl = rl->prev;	/* definitely before: earlier region */
! 		else if ((rl->offset <= offset) && (rl->offset + rl->length >= offset + len))
  			return rl->attributeid;		/* definitely within */
  		else if (rl->offset + rl->length < offset)
! 			return -1;			/* hole */
! 		else return -1;				/* overlapping: error */
  	}
! 	return -1;					/* reached end of file */
  }
  
  #else	/*STRUCTURED_QUERIES*/
***************
*** 542,552 ****
  }
  
  int region_initialize()
- {
- 	return 0;
- }
- 
- int region_desrtroy()
  {
  	return 0;
  }
--- 566,571 ----
