diff --git a/examples/pdf-mod-info.cc b/examples/pdf-mod-info.cc index 84cc8415..e8defa32 100644 --- a/examples/pdf-mod-info.cc +++ b/examples/pdf-mod-info.cc @@ -190,8 +190,7 @@ int main(int argc, char* argv[]) else { QTC::TC("examples", "pdf-mod-info file no info"); - std::map vacant; - fileinfo = fileinfo.newDictionary(vacant); + fileinfo = QPDFObjectHandle::newDictionary(); filetrailer.replaceKey("/Info", fileinfo); } } diff --git a/libqpdf/QPDFObjectHandle.cc b/libqpdf/QPDFObjectHandle.cc index d0d911f7..4db0f6fe 100644 --- a/libqpdf/QPDFObjectHandle.cc +++ b/libqpdf/QPDFObjectHandle.cc @@ -655,8 +655,7 @@ QPDFObjectHandle QPDFObjectHandle::newStream(QPDF* qpdf) { QTC::TC("qpdf", "QPDFObjectHandle newStream"); - std::map keys; - QPDFObjectHandle stream_dict = newDictionary(keys); + QPDFObjectHandle stream_dict = newDictionary(); QPDFObjectHandle result = qpdf->makeIndirectObject( QPDFObjectHandle( new QPDF_Stream(qpdf, 0, 0, stream_dict, 0, 0))); diff --git a/libqpdf/qpdf-c.cc b/libqpdf/qpdf-c.cc index 2be301bb..65a5de72 100644 --- a/libqpdf/qpdf-c.cc +++ b/libqpdf/qpdf-c.cc @@ -340,9 +340,7 @@ void qpdf_set_info_key(qpdf_data qpdf, char const* key, char const* value) QTC::TC("qpdf", "qpdf-c add info to trailer"); trailer.replaceKey( "/Info", - qpdf->qpdf->makeIndirectObject( - QPDFObjectHandle::newDictionary( - std::map()))); + qpdf->qpdf->makeIndirectObject(QPDFObjectHandle::newDictionary())); } else { diff --git a/qpdf/test_driver.cc b/qpdf/test_driver.cc index d2869317..e7b78c4a 100644 --- a/qpdf/test_driver.cc +++ b/qpdf/test_driver.cc @@ -597,9 +597,8 @@ void runtest(int n, char const* filename) QPDFObjectHandle qarray = trailer.getKey("/QArray"); // Force qdict but not qarray to resolve qdict.isDictionary(); - std::map dict_keys; - dict_keys["/NewDict"] = QPDFObjectHandle::newInteger(2); - QPDFObjectHandle new_dict = QPDFObjectHandle::newDictionary(dict_keys); + QPDFObjectHandle new_dict = QPDFObjectHandle::newDictionary(); + new_dict.replaceKey("/NewDict", QPDFObjectHandle::newInteger(2)); try { // Do it wrong first...