GraphicsMagick: QuantumGammaCB(): Fix Coverity issue 381863 "Con...
GraphicsMagick Commits <[email protected]>
| Newsgroups | gmane.comp.video.graphicsmagick.cvs |
|---|---|
| Message-ID | <mailman.14670.1667942726.1459.graphicsmagick-commit@lists.sourceforge.net> |
changeset db3139170761 in /hg/GraphicsMagick details: http://hg.GraphicsMagick.org/hg/GraphicsMagick?cmd=changeset;node=db3139170761 summary: QuantumGammaCB(): Fix Coverity issue 381863 "Control flow issues (DEADCODE)" diffstat: ChangeLog | 3 +++ magick/operator.c | 6 ++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diffs (31 lines): diff -r a9598ac346e3 -r db3139170761 ChangeLog --- a/ChangeLog Tue Nov 08 15:22:29 2022 -0600 +++ b/ChangeLog Tue Nov 08 15:25:14 2022 -0600 @@ -1,5 +1,8 @@ 2022-11-08 Bob Friesenhahn <[email protected]> + * magick/operator.c (QuantumGammaCB): Fix Coverity issue 381863 + "Control flow issues (DEADCODE)". + * coders/png.c (ReadOnePNGImage): Fix Coverity issue 381864 "BAD_SHIFT". diff -r a9598ac346e3 -r db3139170761 magick/operator.c --- a/magick/operator.c Tue Nov 08 15:22:29 2022 -0600 +++ b/magick/operator.c Tue Nov 08 15:25:14 2022 -0600 @@ -772,11 +772,13 @@ 1.0/immutable_context->double_value)); } } + + if (MagickFail == status) + return status; #else ARG_NOT_USED(*mutable_context); + ARG_NOT_USED(status); #endif - if (MagickFail == status) - return status; switch (immutable_context->channel) {