tlog(TL_CRIT|TL_EXIT, "sizeof(Opaque) mismatch");
if ( dh->headersize != SFSTDHSZ )
tlog(TL_CRIT|TL_EXIT, "Tree's header size mismatch (should be %d but %d bytes)", SFSTDHSZ, dh->headersize);
- if ( size && size != dh->totalen + SFSTDHSZ )
- tlog(TL_CRIT|TL_EXIT, "Memory size mismatch (should be %d but %d bytes)", dh->totalen + SFSTDHSZ, size);
+ if ( size && size != dh->totalen + SFSTDHSZ + dh->extrasize )
+ tlog(TL_CRIT|TL_EXIT, "Memory size mismatch (should be %d but %d bytes)", dh->totalen + SFSTDHSZ + dh->extrasize , size);
info->totalen = dh->totalen;
info->nnodes = dh->nnodes;