summaryrefslogtreecommitdiff
path: root/vcl/unx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-11-22 09:33:32 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-11-23 06:59:31 +0100
commit7a1c21e53fc4733a4bb52282ce0098fcc085ab0e (patch)
treec1b90f74e1ce9e9f3a852f398890899459189cab /vcl/unx
parentc24c32bf71b8e64bd0d36e511f554e1f6c015842 (diff)
loplugin:simplifybool for negation of comparison operator
Change-Id: Ie56daf560185274754afbc7a09c432b5c2793791 Reviewed-on: https://gerrit.libreoffice.org/45068 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/unx')
-rw-r--r--vcl/unx/generic/print/common_gfx.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/vcl/unx/generic/print/common_gfx.cxx b/vcl/unx/generic/print/common_gfx.cxx
index 40894081cbd1..887c4370d356 100644
--- a/vcl/unx/generic/print/common_gfx.cxx
+++ b/vcl/unx/generic/print/common_gfx.cxx
@@ -378,7 +378,7 @@ void
PrinterGfx::DrawPolygon (sal_uInt32 nPoints, const Point* pPath)
{
// premature end of operation
- if (!(nPoints > 1) || (pPath == nullptr) || !(maFillColor.Is() || maLineColor.Is()))
+ if (nPoints <= 0 || (pPath == nullptr) || !(maFillColor.Is() || maLineColor.Is()))
return;
// setup closed path
@@ -529,7 +529,7 @@ PrinterGfx::DrawPolygonBezier (sal_uInt32 nPoints, const Point* pPath, const Pol
const sal_uInt32 nBezString = 1024;
sal_Char pString[nBezString];
// premature end of operation
- if (!(nPoints > 1) || (pPath == nullptr) || !(maFillColor.Is() || maLineColor.Is()))
+ if (nPoints <= 0 || (pPath == nullptr) || !(maFillColor.Is() || maLineColor.Is()))
return;
snprintf(pString, nBezString, "%li %li moveto\n", pPath[0].X(), pPath[0].Y());