-
Run this: for i in **/*.cc **/*.c **/*.h **/*.hh; do clang-format < $i >| $i.new && mv $i.new $i done
-
Use get() and use_count() instead. Add #define NO_POINTERHOLDER_DEPRECATION to remove deprecation markers for these only. This commit also removes all deprecated PointerHolder API calls from qpdf's code except in PointerHolder's test suite, which must continue to test the deprecated APIs.
-
Use PointerHolder in several places where manually memory allocation and deallocation were being used. This helps to protect against memory leaks when exceptions are thrown in surprising places.
-
There were a few places in the code that were checking that a pointer wasn't null before deleting it, even though C++ has always allowed delete 0. Most of the code did not perform these checks.
-
During periods of intensive operation on a specific file, this method can reduce the overhead of repeated open/close operations.
-
ClosedFileInputSource is an input source that keeps the file closed when not reading it.