drh,

Your commit 34dc2a4956 regarding this problem does not seem entirely correct to me. The return value &p->aFile[i] should be changed for &pBase->aFile[i] according to my testing (see below).

If I'm mistaking, could you please explain my mistake?

F.

François Vogel said on 13/01/2012 23:17:
François Vogel said on 13/01/2012 23:10:
The loop in which this fossil_stricmp is called is the following:

for(i=0; i<pBase->nFile; i++){
if( fossil_stricmp(zName, p->aFile[i].zName)==0 ){
return &p->aFile[i];
}
}

I would suggest the call to fossil_stricmp should read:

fossil_stricmp(zName, pBase->aFile[i].zName)

instead.

Btw, to be complete, the return value inside the for loop should be
corrected as well. Final suggested version of manifest.c:1249-1253:

for(i=0; i<pBase->nFile; i++){
if( fossil_stricmp(zName, pBase->aFile[i].zName)==0 ){
return &pBase->aFile[i];
}
}


Changing this, compiling and trying my tests again shows the crash is
gone.

Definitely confirmed.

F.
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to