File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -420,6 +420,9 @@ _pdfioObjLoad(pdfio_obj_t *obj) // I - Object
420420 }
421421
422422 ptr += 3 ;
423+ while (* ptr && isspace (* ptr & 255 ))
424+ ptr ++ ;
425+
423426 _pdfioFileConsume (obj -> pdf , (size_t )(ptr - line ));
424427
425428 // Then grab the object value...
@@ -438,11 +441,14 @@ _pdfioObjLoad(pdfio_obj_t *obj) // I - Object
438441 return (false);
439442 }
440443
444+ if (tb .bufptr && tb .bufptr < tb .bufend && (* (tb .bufptr ) == 0x0d || * (tb .bufptr ) == 0x0a ))
445+ tb .bufptr ++ ; // Skip trailing CR or LF after token
446+
441447 _pdfioTokenFlush (& tb );
442448
443449 if (!strcmp (line , "stream" ))
444450 {
445- // Yes, save its location...
451+ // Yes, this is an embedded stream so save its location...
446452 obj -> stream_offset = _pdfioFileTell (obj -> pdf );
447453 PDFIO_DEBUG ("_pdfioObjLoad: stream_offset=%lu.\n" , (unsigned long )obj -> stream_offset );
448454 }
Original file line number Diff line number Diff line change 11//
22// Public header file for PDFio.
33//
4- // Copyright © 2021-2022 by Michael R Sweet.
4+ // Copyright © 2021-2023 by Michael R Sweet.
55//
66// Licensed under Apache License v2.0. See the file "LICENSE" for more
77// information.
@@ -34,7 +34,7 @@ extern "C" {
3434// Version...
3535//
3636
37- # define PDFIO_VERSION "1.1.1 "
37+ # define PDFIO_VERSION "1.1.2 "
3838
3939
4040//
You can’t perform that action at this time.
0 commit comments