summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2017-03-10 16:45:31 +0100
committerStephan Bergmann <sbergman@redhat.com>2017-03-10 16:45:31 +0100
commit516bb69247c79ea0913856b9b053599f57ad90fb (patch)
tree8bb12507e95fa7b7b81a0d2e2efadeb68f2ca1c6 /vcl
parent3114d8a12eb14f27229ecaad6d810e2020b86441 (diff)
The previous commit wasn't really thought through
Change-Id: I88e44e637e2ac93b4deed42a2d0f94b0a973c995
Diffstat (limited to 'vcl')
-rw-r--r--vcl/headless/svpprn.cxx2
-rw-r--r--vcl/unx/generic/print/genprnpsp.cxx2
2 files changed, 2 insertions, 2 deletions
diff --git a/vcl/headless/svpprn.cxx b/vcl/headless/svpprn.cxx
index 50a44320320c..0db8fd8cfad4 100644
--- a/vcl/headless/svpprn.cxx
+++ b/vcl/headless/svpprn.cxx
@@ -105,7 +105,7 @@ static void copyJobDataToJobSetup( ImplJobSetup* pJobSetup, JobData& rData )
nPaperBin < pKey->countValues();
nPaperBin++ );
pJobSetup->SetPaperBin(
- (nPaperBin < 0 || nPaperBin >= pKey->countValues()
+ (nPaperBin == pKey->countValues()
|| pValue == pKey->getDefaultValue())
? 0xffff : nPaperBin);
}
diff --git a/vcl/unx/generic/print/genprnpsp.cxx b/vcl/unx/generic/print/genprnpsp.cxx
index 179057172ec2..f8321b73d650 100644
--- a/vcl/unx/generic/print/genprnpsp.cxx
+++ b/vcl/unx/generic/print/genprnpsp.cxx
@@ -201,7 +201,7 @@ static void copyJobDataToJobSetup( ImplJobSetup* pJobSetup, JobData& rData )
nPaperBin < pKey->countValues();
nPaperBin++);
pJobSetup->SetPaperBin(
- nPaperBin < 0 || nPaperBin >= pKey->countValues() ? 0 : nPaperBin);
+ nPaperBin == pKey->countValues() ? 0 : nPaperBin);
}
// copy duplex