libhtml: fix potential linked list corruption

the difficulty is freeing items while parsing because items might already
be linked into various linked lists like in docinfo.images or form.fiels.
so we link images, tables and formfields to the docinfo as the final step
of getitems() pass using the new recursive function linkitems(). as only
reachable items get linked theres no danger of dangeling pointers.
This commit is contained in:
cinap_lenrek 2013-09-05 00:55:58 +02:00
parent cca9a1b523
commit 95fac5e873
2 changed files with 69 additions and 39 deletions

View file

@ -253,7 +253,6 @@ struct Ifloat
int y; /* y coord of top */
uchar side; /* margin it floats to: ALleft or ALright */
uchar infloats; /* true if this has been added to a lay.floats */
Ifloat* nextfloat; /* in list of floats */
};