mirror of
https://github.com/michaelrsweet/pdfio.git
synced 2024-11-16 02:18:24 +01:00
Fix another coverity issue.
This commit is contained in:
parent
63c0fc1926
commit
a962b1d069
@ -285,6 +285,10 @@ pdfioFileCreateObj(
|
|||||||
_pdfio_value_t value; // Object value
|
_pdfio_value_t value; // Object value
|
||||||
|
|
||||||
|
|
||||||
|
// Range check input...
|
||||||
|
if (!pdf || !dict)
|
||||||
|
return (NULL);
|
||||||
|
|
||||||
value.type = PDFIO_VALTYPE_DICT;
|
value.type = PDFIO_VALTYPE_DICT;
|
||||||
value.value.dict = dict;
|
value.value.dict = dict;
|
||||||
|
|
||||||
@ -372,6 +376,9 @@ pdfioFileCreatePage(pdfio_file_t *pdf, // I - PDF file
|
|||||||
else
|
else
|
||||||
dict = pdfioDictCreate(pdf);
|
dict = pdfioDictCreate(pdf);
|
||||||
|
|
||||||
|
if (!dict)
|
||||||
|
return (NULL);
|
||||||
|
|
||||||
// Make sure the page dictionary has all of the required keys...
|
// Make sure the page dictionary has all of the required keys...
|
||||||
if (!_pdfioDictGetValue(dict, "CropBox"))
|
if (!_pdfioDictGetValue(dict, "CropBox"))
|
||||||
pdfioDictSetRect(dict, "CropBox", &pdf->crop_box);
|
pdfioDictSetRect(dict, "CropBox", &pdf->crop_box);
|
||||||
|
Loading…
Reference in New Issue
Block a user