diff options
author | Chris Sherlock <chris.sherlock79@gmail.com> | 2015-01-13 01:33:00 +1100 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2015-01-12 18:28:16 +0000 |
commit | b0786565dbe15fed3b58d00138a5788d5c22e0c1 (patch) | |
tree | ee9119da54e24d81b6229cca445a788a5780ddb1 /vcl | |
parent | 8b2a9a37306a7febf28e419280d1782ff230761a (diff) |
vcl: possible regression introduced in fa1f37753d2826a0 as part of i99295
I believe the intent was to "retarget unresolved pLogCluster[n] to a glyph inside the cluster".
Unfortunately in the loop that detects clusters there was a typo and we are only indexing
element 0 of the array:
// retarget unresolved pLogCluster[n] to a glyph inside the cluster
// TODO: better do it while the deleted-glyph markers are still there
for( n = 0; n < nCharCount; ++n )
if( (p = pLogCluster[0]) >= 0 )
break;
That just doesn't make any sense, I believe we should be accessing pLogCluster[n].
If not, then why not just do:
p = pLogCluster[0];
n = nCharCount - 1;
Change-Id: I9d8873541b5c794071d69c0f63df88f17a352904
Reviewed-on: https://gerrit.libreoffice.org/13876
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/gdi/sallayout.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/source/gdi/sallayout.cxx b/vcl/source/gdi/sallayout.cxx index ad34efd06bf2..4ca12b93cbcd 100644 --- a/vcl/source/gdi/sallayout.cxx +++ b/vcl/source/gdi/sallayout.cxx @@ -1020,7 +1020,7 @@ void GenericSalLayout::ApplyDXArray( ImplLayoutArgs& rArgs ) // retarget unresolved pLogCluster[n] to a glyph inside the cluster // TODO: better do it while the deleted-glyph markers are still there for( n = 0; n < nCharCount; ++n ) - if( (p = pLogCluster[0]) >= 0 ) + if( (p = pLogCluster[n]) >= 0 ) break; if( n >= nCharCount ) return; |