summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2020-01-25 13:16:06 +0100
committerStephan Bergmann <sbergman@redhat.com>2020-01-25 17:03:13 +0100
commit60eca4ec0d35da6f943a5894068e1b8d8d666046 (patch)
tree8dc3b561750063ab92cc674ff49bd017bc192b9d /vcl
parent4e9d00b17d081e012aceb5eb3ae611bd695e9e28 (diff)
Fix off-by-one error in PPDContext::getModifiedKey
...introduced with 19be86249dcc5b13b3c95f5469600fa2bc1b749b "Simplify containers iterations in vcl" Change-Id: I95bd303b744796a2b585575c4cdf548e4a0a729f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87379 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Arkadiy Illarionov <qarkai@gmail.com> Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/unx/generic/printer/ppdparser.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/unx/generic/printer/ppdparser.cxx b/vcl/unx/generic/printer/ppdparser.cxx
index 96f2bdc0e253..a8554055ab8b 100644
--- a/vcl/unx/generic/printer/ppdparser.cxx
+++ b/vcl/unx/generic/printer/ppdparser.cxx
@@ -1646,7 +1646,7 @@ PPDContext& PPDContext::operator=( PPDContext&& rCopy )
const PPDKey* PPDContext::getModifiedKey( int n ) const
{
- if( m_aCurrentValues.size() < static_cast<hash_type::size_type>(n) )
+ if( m_aCurrentValues.size() <= static_cast<hash_type::size_type>(n) )
return nullptr;
hash_type::const_iterator it = m_aCurrentValues.begin();