aboutsummaryrefslogtreecommitdiffstats
path: root/libqpdf/qpdf
diff options
context:
space:
mode:
authorJay Berkenbilt <ejb@ql.org>2022-04-24 15:05:50 +0200
committerJay Berkenbilt <ejb@ql.org>2022-04-24 15:05:50 +0200
commit4925f0d18c5554bf96d8cb853b5a017e0d18fda2 (patch)
tree0be25169d5fe7b306b9a8b84bb8f300f96869342 /libqpdf/qpdf
parent68e721981a1fe4f1398d811bb8ed99af0e100da8 (diff)
downloadqpdf-4925f0d18c5554bf96d8cb853b5a017e0d18fda2.tar.zst
Have dictionary/streams mutators take const& where possible
Diffstat (limited to 'libqpdf/qpdf')
-rw-r--r--libqpdf/qpdf/QPDF_Dictionary.hh2
-rw-r--r--libqpdf/qpdf/QPDF_Stream.hh2
2 files changed, 2 insertions, 2 deletions
diff --git a/libqpdf/qpdf/QPDF_Dictionary.hh b/libqpdf/qpdf/QPDF_Dictionary.hh
index 8626d59b..42ee6cf9 100644
--- a/libqpdf/qpdf/QPDF_Dictionary.hh
+++ b/libqpdf/qpdf/QPDF_Dictionary.hh
@@ -28,7 +28,7 @@ class QPDF_Dictionary: public QPDFObject
std::map<std::string, QPDFObjectHandle> const& getAsMap() const;
// Replace value of key, adding it if it does not exist
- void replaceKey(std::string const& key, QPDFObjectHandle);
+ void replaceKey(std::string const& key, QPDFObjectHandle const&);
// Remove key, doing nothing if key does not exist
void removeKey(std::string const& key);
// If object is null, remove key; otherwise, replace key
diff --git a/libqpdf/qpdf/QPDF_Stream.hh b/libqpdf/qpdf/QPDF_Stream.hh
index a6ee9551..ba456e76 100644
--- a/libqpdf/qpdf/QPDF_Stream.hh
+++ b/libqpdf/qpdf/QPDF_Stream.hh
@@ -62,7 +62,7 @@ class QPDF_Stream: public QPDFObject
void
addTokenFilter(std::shared_ptr<QPDFObjectHandle::TokenFilter> token_filter);
- void replaceDict(QPDFObjectHandle new_dict);
+ void replaceDict(QPDFObjectHandle const& new_dict);
static void registerStreamFilter(
std::string const& filter_name,