diff options
author | Albert Astals Cid <aacid@kde.org> | 2020-07-03 23:26:44 +0200 |
---|---|---|
committer | Albert Astals Cid <aacid@kde.org> | 2020-07-03 23:50:30 +0200 |
commit | 0d48722746b9702e219df58ad14cee6184a62bef (patch) | |
tree | ea8edc274940587c4ac30fa1f4fdffe619225a02 | |
parent | afa4803f79b32c47fc2d187198b9f710f5302df0 (diff) |
Tweak code that clang-format doesn't understand
-rw-r--r-- | glib/poppler-document.h | 2 | ||||
-rw-r--r-- | poppler/JBIG2Stream.cc | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/glib/poppler-document.h b/glib/poppler-document.h index e0753a0d..c108250e 100644 --- a/glib/poppler-document.h +++ b/glib/poppler-document.h @@ -187,6 +187,7 @@ typedef enum * * Permissions */ +/* clang-format off */ typedef enum /*< flags >*/ { POPPLER_PERMISSIONS_OK_TO_PRINT = 1 << 0, @@ -200,6 +201,7 @@ typedef enum /*< flags >*/ POPPLER_PERMISSIONS_FULL = (POPPLER_PERMISSIONS_OK_TO_PRINT | POPPLER_PERMISSIONS_OK_TO_MODIFY | POPPLER_PERMISSIONS_OK_TO_COPY | POPPLER_PERMISSIONS_OK_TO_ADD_NOTES | POPPLER_PERMISSIONS_OK_TO_FILL_FORM | POPPLER_PERMISSIONS_OK_TO_EXTRACT_CONTENTS | POPPLER_PERMISSIONS_OK_TO_ASSEMBLE | POPPLER_PERMISSIONS_OK_TO_PRINT_HIGH_RESOLUTION) } PopplerPermissions; +/* clang-format on */ /** * PopplerPDFSubtype: diff --git a/poppler/JBIG2Stream.cc b/poppler/JBIG2Stream.cc index a861da21..9450985b 100644 --- a/poppler/JBIG2Stream.cc +++ b/poppler/JBIG2Stream.cc @@ -1375,7 +1375,8 @@ void JBIG2Stream::readSegments() { } refFlags = (refFlags << 24) | (c1 << 16) | (c2 << 8) | c3; nRefSegs = refFlags & 0x1fffffff; - for (unsigned int i = 0; i < (nRefSegs + 9) >> 3; ++i) { + const unsigned int nCharsToRead = (nRefSegs + 9) >> 3; + for (unsigned int i = 0; i < nCharsToRead; ++i) { if ((c1 = curStr->getChar()) == EOF) { goto eofError1; } |