mirror of
https://github.com/qpdf/qpdf.git
synced 2025-01-22 22:58:33 +00:00
Change QPDFParser::setDescription to take a shared_ptr<QPDFObject> parameter
This commit is contained in:
parent
8391022416
commit
b19e06fd8b
@ -381,7 +381,7 @@ QPDFParser::parse(bool& empty, bool content_stream)
|
||||
"dictionary ended prematurely; "
|
||||
"using null as value for last key");
|
||||
val = QPDFObjectHandle::newNull();
|
||||
setDescription(val, offset);
|
||||
setDescription(val.obj, offset);
|
||||
} else {
|
||||
val = olist.at(++i);
|
||||
}
|
||||
@ -432,9 +432,10 @@ QPDFParser::parse(bool& empty, bool content_stream)
|
||||
}
|
||||
|
||||
void
|
||||
QPDFParser::setDescription(QPDFObjectHandle oh, qpdf_offset_t parsed_offset)
|
||||
QPDFParser::setDescription(
|
||||
std::shared_ptr<QPDFObject>& obj, qpdf_offset_t parsed_offset)
|
||||
{
|
||||
if (auto& obj = oh.obj) {
|
||||
if (obj) {
|
||||
obj->setDescription(context, description, parsed_offset);
|
||||
}
|
||||
}
|
||||
|
@ -42,7 +42,8 @@ class QPDFParser
|
||||
void warn(qpdf_offset_t offset, std::string const& msg) const;
|
||||
void warn(std::string const& msg) const;
|
||||
static void warn(QPDF*, QPDFExc const&);
|
||||
void setDescription(QPDFObjectHandle oh, qpdf_offset_t parsed_offset);
|
||||
void setDescription(
|
||||
std::shared_ptr<QPDFObject>& obj, qpdf_offset_t parsed_offset);
|
||||
std::shared_ptr<InputSource> input;
|
||||
std::string const& object_description;
|
||||
QPDFTokenizer& tokenizer;
|
||||
|
Loading…
x
Reference in New Issue
Block a user