Commit 0ae19c375ebc24c303765953ff127ecb6a4664dc

Authored by Jay Berkenbilt
1 parent 1e0b1025

TODO: Remove fixed item, move item into ABI section

Showing 1 changed file with 12 additions and 39 deletions
... ... @@ -16,6 +16,18 @@ Comments appear in the code prefixed by "ABI"
16 16 * QPDFPageObjectHelper::placeFormXObject: name should be std::string
17 17 const& (issue #374)
18 18  
  19 +* (Source compatibiliy) As somewhat discussed in issue 219, the
  20 + original pipeStreamData in QPDF_Stream has various logic for
  21 + reporting warnings and letting the caller retry. This logic is not
  22 + implemented for stream data providers. When copying foreign streams,
  23 + qpdf uses a stream data provider (QPDF::CopiedStreamDataProvider) to
  24 + read the stream data from the original file. While a warning is
  25 + issued for that case, there is no way to actually propagate failure
  26 + information back through because
  27 + StreamDataProvider::provideStreamData doesn't take the
  28 + suppress_warnings or will_retry options, and adding them would break
  29 + source compatibility.
  30 +
19 31 C++-11
20 32 ======
21 33  
... ... @@ -392,45 +404,6 @@ I find it useful to make reference to them in this list
392 404 logic error and what could happen because of malformed user input.
393 405 See also ../misc/linearization-errors.
394 406  
395   - * There are a few known limitations of copying foreign streams. These
396   - are somewhat discussed in github issue 219. They are most likely
397   - not worth fixing.
398   -
399   - * The original pipeStreamData in QPDF_Stream has various logic for
400   - reporting warnings and letting the caller retry. This logic is
401   - not implemented for stream data providers. When copying foreign
402   - streams, qpdf uses a stream data provider
403   - (QPDF::CopiedStreamDataProvider) to read the stream data from the
404   - original file. While a warning is issued for that case, there is
405   - no way to actually propagate failure information back through
406   - because StreamDataProvider::provideStreamData doesn't take the
407   - suppress_warnings or will_retry options, and adding them would
408   - break source compatibility.
409   -
410   - * When copying streams that use StreamDataProvider provider, the
411   - original QPDF object must still be kept around. This is the case
412   - of where QPDF q1 has a stream for which replaceStreamData was
413   - called to provide a StreamDataProvider, and then that stream from
414   - q1 was subsequently copied to q2. In that case, q1 must be kept
415   - around until q2 is written. That is a pretty unusual case as,
416   - most of the time, people could just attach the stream data
417   - provider directly to the q2. That said, it actually appears in
418   - qpdf itself. qpdf allows you to combine the --pages and --split
419   - options. In that case, a merged file, which uses
420   - StreamDataProvider to access the original stream, is subsequently
421   - copied to the final split output files. Solving this restriction
422   - is difficult and would probably require breaking source
423   - compatibility because QPDF_Stream doesn't have enough information
424   - to know whether the original QPDF object is needed by the
425   - stream's data provider. Also, the interface is designed to pass
426   - the object ID and generation of the object whose data is being
427   - provided so the provider can use it for lookup or any other
428   - purpose. As such, copying a stream data provider to a new stream
429   - potentially changes the meaning of the parameters passed to the
430   - provider. This happens with CopiedStreamDataProvider, which uses
431   - the object ID and generation of the new stream to locate the
432   - parameters of the old stream.
433   -
434 407 * If I ever decide to make appearance stream-generation aware of
435 408 fonts or font metrics, see email from Tobias with Message-ID
436 409 <5C3C9C6C.8000102@thax.hardliners.org> dated 2019-01-14.
... ...