summaryrefslogtreecommitdiff
path: root/source/fitz/filter-fax.c
AgeCommit message (Collapse)Author
2018-04-03Don't implicitly drop in fz_open_* chained filters.Tor Andersson
2017-04-27Include required system headers.Tor Andersson
2016-06-17Use 'size_t' instead of int as appropriate.Robin Watts
This silences the many warnings we get when building for x64 in windows. This does not address any of the warnings we get in thirdparty libraries - in particular harfbuzz. These look (at a quick glance) harmless though.
2015-02-25filter-fax.c: remove cf_uncompressed_decode, it's never usedJoseph Heenan
2015-02-17Add ctx parameter and remove embedded contexts for API regularity.Tor Andersson
Purge several embedded contexts: Remove embedded context in fz_output. Remove embedded context in fz_stream. Remove embedded context in fz_device. Remove fz_rebind_stream (since it is no longer necessary). Remove embedded context in svg_device. Remove embedded context in XML parser. Add ctx argument to fz_document functions. Remove embedded context in fz_document. Remove embedded context in pdf_document. Remove embedded context in pdf_obj. Make fz_page independent of fz_document in the interface. We shouldn't need to pass the document to all functions handling a page. If a page is tied to the source document, it's redundant; otherwise it's just pointless. Fix reference counting oddity in fz_new_image_from_pixmap.
2015-02-17Rename fz_close_* and fz_free_* to fz_drop_*.Tor Andersson
Rename fz_close to fz_drop_stream. Rename fz_close_archive to fz_drop_archive. Rename fz_close_output to fz_drop_output. Rename fz_free_* to fz_drop_*. Rename pdf_free_* to pdf_drop_*. Rename xps_free_* to xps_drop_*.
2014-03-17Rework fz_streams.Robin Watts
Currently fz_streams have a 4K buffer within their header. The call to read from a stream fills this buffer, resulting in more data being pulled from any underlying stream than we might like. This causes problems with the forthcoming 'leech' filter. Here we simplify the fields available in the public stream header. No specific buffer is given; simply the read and write pointers. The underlying 'read' function is replaced by a 'next' function that makes the next block of data available and returns the first character of it (or EOF). A caller to the 'next' function should supply the maximum number of bytes that it knows it will need (possibly not now, but eventually). This enables the underlying stream to efficiently decode just enough. The underlying stream is free to return fewer, or a greater number if it wants to. The exact size of the 'block' of data returned will depend on the filter in use and (possibly) the data therein. Callers can get the currently available amount of data by calling fz_available (but again should pass the maximum amount of data they know they will need). The only time this will ever return 0 is if we have hit EOF.
2014-01-08sanitize number of columns in fz_open_faxdSimon Bünzli
If columns is quite close to INT_MAX, the column index max overflow in find_changing which causes an access violation in the next getbits. This happens e.g. with 0c76a20163f30ea8ec860c4e588ce337_signal_sigsegv_5e7b28_9115_7127.pdf
2014-01-02Add rebinding for fz_streams.Robin Watts
2013-09-27fix bug 694573Simon Bünzli
Currently, MuPDF throws away entire CCITT encoded images whenever an error happens in the code stream. Other PDF readers seem to rather render what has been decoded up to the point of the error. This patch enables such behavior for MuPDF as well.
2013-08-28optionally detect initial EOL in CCITTFaxDecode streamsSimon Bünzli
If /EndOfLine is set for a CCITTFaxDecode stream, the image must start with an EOL per the spec. Other readers seem to ignore all data up to the first EOL in that case - instead of rejecting such images as broken. Required for e.g. "1848 - 1d faxd doesn't start with EOL.pdf".
2013-06-20Rearrange source files.Tor Andersson