kevinboone / epub2txt2

A simple command-line utility for Linux, for extracting text from EPUB documents.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fd leak when opening htmls

gumblex opened this issue · comments

In file https://github.com/kevinboone/epub2txt2/blob/master/src/wstring.c#L83 , there is no close(). When the epub has many htmls, there will be an error "Too many open files".

You're absolutely right. Oops :/ I guess I never tested with an EPUB that had enough embedded files to expose this defect. I have commit what I think is the appropriate fix -- feel free to test and let me know if there are still problems.

Seems ok.