The following code is consistently throwing 

xxx in free(): warning: modified (page-) pointer.


on the free(ENTRY.ptr) line.

ENTRY is a datum, the trace printf's show that ENTRY.dptr 
has the same value immediately after the dbm_fetch as it
has immediately before the free, but the message continues 
to be displayed... Anyone know what is going on here?

   ENTRY = dbm_fetch(db,URL);
   printf("%d\n",ENTRY.dptr);
    bzero(etemp,1000);
    if(ENTRY.dptr != NULL){
    strncpy(etemp,ENTRY.dptr,ENTRY.dsize);
    //      ENTRY.dptr[ENTRY.dsize]=0;
      sprintf(temp,"%s\xb3\xb3%s",URL.dptr,etemp);
    }
    else{
//      printf("ERRER %d %s\n",dbm_error(db),array[y]);
      sprintf(temp,"%s\xb3\xb3%s",URL.dptr,"0");
    }
    free(URL.dptr);
    if(ENTRY.dptr != NULL){
     printf("%d\n",ENTRY.dptr);
    free(ENTRY.dptr);


Sean Peck
News Index -- The original News Only Search Engine.
http://www.newsindex.com/



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message

Reply via email to