aboutsummaryrefslogtreecommitdiffstats
path: root/libqpdf/QPDF.cc
diff options
context:
space:
mode:
authorm-holger <m-holger@kubitscheck.org>2022-09-21 18:49:21 +0200
committerJay Berkenbilt <jberkenbilt@users.noreply.github.com>2022-09-21 21:57:14 +0200
commit2e6869483bba657515aad305a3aa7013e477c448 (patch)
tree0487066d6069127082a5f176baf031e6ec6308b0 /libqpdf/QPDF.cc
parentda67a0aa043c2c8ad129fbc87b93afcdab7042a7 (diff)
downloadqpdf-2e6869483bba657515aad305a3aa7013e477c448.tar.zst
Replace calls to QUtil::int_to_string with std::to_string
Diffstat (limited to 'libqpdf/QPDF.cc')
-rw-r--r--libqpdf/QPDF.cc34
1 files changed, 17 insertions, 17 deletions
diff --git a/libqpdf/QPDF.cc b/libqpdf/QPDF.cc
index dd6037c1..91006f13 100644
--- a/libqpdf/QPDF.cc
+++ b/libqpdf/QPDF.cc
@@ -773,9 +773,9 @@ QPDF::read_xref(qpdf_offset_t xref_offset)
"",
0,
(std::string("reported number of objects (") +
- QUtil::int_to_string(size) +
+ std::to_string(size) +
") is not one plus the highest object number (" +
- QUtil::int_to_string(max_obj) + ")"));
+ std::to_string(max_obj) + ")"));
}
// We no longer need the deleted_objects table, so go ahead and
@@ -954,7 +954,7 @@ QPDF::read_xrefTable(qpdf_offset_t xref_offset)
this->m->file->getName(),
"xref table",
this->m->file->getLastOffset(),
- "invalid xref entry (obj=" + QUtil::int_to_string(i) + ")");
+ "invalid xref entry (obj=" + std::to_string(i) + ")");
}
if (type == 'f') {
// Save deleted items until after we've checked the
@@ -1160,7 +1160,7 @@ QPDF::processXRefStream(qpdf_offset_t xref_offset, QPDFObjectHandle& xref_obj)
"xref stream",
xref_offset,
("Cross-reference stream's /Index's item " +
- QUtil::int_to_string(i) + " is not an integer"));
+ std::to_string(i) + " is not an integer"));
}
}
QTC::TC("qpdf", "QPDF xref /Index is array", n_index == 2 ? 0 : 1);
@@ -1181,9 +1181,9 @@ QPDF::processXRefStream(qpdf_offset_t xref_offset, QPDFObjectHandle& xref_obj)
xref_offset,
("Cross-reference stream claims to contain"
" too many entries: " +
- QUtil::int_to_string(indx.at(i)) + " " +
- QUtil::uint_to_string(max_num_entries) + " " +
- QUtil::uint_to_string(num_entries)));
+ std::to_string(indx.at(i)) + " " +
+ std::to_string(max_num_entries) + " " +
+ std::to_string(num_entries)));
}
num_entries += toS(indx.at(i));
}
@@ -1203,8 +1203,8 @@ QPDF::processXRefStream(qpdf_offset_t xref_offset, QPDFObjectHandle& xref_obj)
xref_offset,
("Cross-reference stream data has the wrong size;"
" expected = " +
- QUtil::uint_to_string(expected_size) +
- "; actual = " + QUtil::uint_to_string(actual_size)));
+ std::to_string(expected_size) +
+ "; actual = " + std::to_string(actual_size)));
if (expected_size > actual_size) {
throw x;
} else {
@@ -1356,7 +1356,7 @@ QPDF::insertXrefEntry(int obj, int f0, qpdf_offset_t f1, int f2, bool overwrite)
this->m->file->getName(),
"xref stream",
this->m->file->getLastOffset(),
- "unknown xref stream entry type " + QUtil::int_to_string(f0));
+ "unknown xref stream entry type " + std::to_string(f0));
break;
}
}
@@ -1747,7 +1747,7 @@ QPDF::recoverStreamLength(
input->getName(),
this->m->last_object_description,
stream_offset,
- "recovered stream length: " + QUtil::uint_to_string(length)));
+ "recovered stream length: " + std::to_string(length)));
}
QTC::TC("qpdf", "QPDF recovered stream length");
@@ -2026,8 +2026,8 @@ QPDF::resolveObjectsInStream(int obj_stream_number)
this->m->file->getName(),
this->m->last_object_description,
this->m->file->getLastOffset(),
- ("supposed object stream " +
- QUtil::int_to_string(obj_stream_number) + " is not a stream"));
+ ("supposed object stream " + std::to_string(obj_stream_number) +
+ " is not a stream"));
}
// For linearization data in the object, use the data from the
@@ -2045,8 +2045,8 @@ QPDF::resolveObjectsInStream(int obj_stream_number)
qpdf_e_damaged_pdf,
this->m->last_object_description,
this->m->file->getLastOffset(),
- ("supposed object stream " +
- QUtil::int_to_string(obj_stream_number) + " has wrong type"));
+ ("supposed object stream " + std::to_string(obj_stream_number) +
+ " has wrong type"));
}
if (!(dict.getKey("/N").isInteger() && dict.getKey("/First").isInteger())) {
@@ -2055,7 +2055,7 @@ QPDF::resolveObjectsInStream(int obj_stream_number)
this->m->file->getName(),
this->m->last_object_description,
this->m->file->getLastOffset(),
- ("object stream " + QUtil::int_to_string(obj_stream_number) +
+ ("object stream " + std::to_string(obj_stream_number) +
" has incorrect keys"));
}
@@ -2069,7 +2069,7 @@ QPDF::resolveObjectsInStream(int obj_stream_number)
// line-break
new BufferInputSource(
(this->m->file->getName() + " object stream " +
- QUtil::int_to_string(obj_stream_number)),
+ std::to_string(obj_stream_number)),
bp.get()));
for (int i = 0; i < n; ++i) {