Date: Sat, 15 Apr 2000 23:24:47 -0400 (EDT) From: Sean Peck <speck@news1.newsindex.com> To: freebsd-hackers@freebsd.org Subject: FREE Problem in BSD? Message-ID: <Pine.BSI.3.95.1000415232147.22112C-100000@news1.newsindex.com>
next in thread | raw e-mail | index | archive | help
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 majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSI.3.95.1000415232147.22112C-100000>
