Commit 31b2cfbb79e0222f666ce3eaec740ed7f225c4a9
1 parent
62833ac7
Fix up a few comments
Showing
2 changed files
with
4 additions
and
7 deletions
include/qpdf/QPDF.hh
| ... | ... | @@ -875,8 +875,8 @@ class QPDF |
| 875 | 875 | }; |
| 876 | 876 | friend class Resolver; |
| 877 | 877 | |
| 878 | - // ParseGuard class allows QPDFObjectHandle to detect re-entrant | |
| 879 | - // resolution | |
| 878 | + // The ParseGuard class allows QPDFObjectHandle to detect | |
| 879 | + // re-entrant parsing. | |
| 880 | 880 | class ParseGuard |
| 881 | 881 | { |
| 882 | 882 | friend class QPDFParser; | ... | ... |
libqpdf/QPDF.cc
| ... | ... | @@ -1947,9 +1947,6 @@ QPDF::resolve(QPDFObjGen const& og) |
| 1947 | 1947 | return; |
| 1948 | 1948 | } |
| 1949 | 1949 | |
| 1950 | - // Check object cache before checking xref table. This allows us | |
| 1951 | - // to insert things into the object cache that don't actually | |
| 1952 | - // exist in the file. | |
| 1953 | 1950 | if (this->m->resolving.count(og)) { |
| 1954 | 1951 | // This can happen if an object references itself directly or |
| 1955 | 1952 | // indirectly in some key that has to be resolved during |
| ... | ... | @@ -2558,8 +2555,8 @@ QPDF::swapObjects(int objid1, int generation1, int objid2, int generation2) |
| 2558 | 2555 | void |
| 2559 | 2556 | QPDF::swapObjects(QPDFObjGen const& og1, QPDFObjGen const& og2) |
| 2560 | 2557 | { |
| 2561 | - // Force objects to be loaded into cache; then swap them in the | |
| 2562 | - // cache. | |
| 2558 | + // Force objects to be read from the input source if needed, then | |
| 2559 | + // swap them in the cache. | |
| 2563 | 2560 | resolve(og1); |
| 2564 | 2561 | resolve(og2); |
| 2565 | 2562 | m->obj_cache[og1].object->swapWith(m->obj_cache[og2].object); | ... | ... |