2
1
mirror of https://github.com/qpdf/qpdf.git synced 2024-12-22 10:58:58 +00:00

Fix errors reported by Coverity

Thanks to Jiri Popelka from Red Hat for sending the output of a
Coverity run over qpdf.
This commit is contained in:
Jay Berkenbilt 2013-07-07 15:35:00 -04:00
parent 66c88995fc
commit 212812d837
3 changed files with 5 additions and 1 deletions

View File

@ -35,6 +35,7 @@ QPDFObjectHandle::ParserCallbacks::terminateParsing()
QPDFObjectHandle::QPDFObjectHandle() :
initialized(false),
qpdf(0),
objid(0),
generation(0),
reserved(false)

View File

@ -70,6 +70,7 @@ QPDFWriter::init()
encryption_V = 0;
encryption_R = 0;
encryption_dict_objid = 0;
pipeline = 0;
next_objid = 1;
cur_stream_length_id = 0;
cur_stream_length = 0;
@ -2695,7 +2696,7 @@ QPDFWriter::writeLinearized()
this->next_objid = part4_first_obj;
enqueuePart(part4);
assert(this->next_objid = after_part4);
assert(this->next_objid == after_part4);
this->next_objid = part6_first_obj;
enqueuePart(part6);
assert(this->next_objid == after_part6);

View File

@ -46,6 +46,7 @@ void run(char const* filename)
// Write to the both pipeline
def3->write(buf, len);
}
fclose(in1);
def1->finish();
delete def1;
@ -69,6 +70,7 @@ void run(char const* filename)
{
inf2->write(buf, len);
}
fclose(in2);
inf2->finish();
delete inf2;