Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNathan Ridge2019-07-08 23:05:23 -0400
committerNathan Ridge2019-07-11 00:00:06 -0400
commit1ea6dac9afbde9875a4da8b25c9403eeab333ab7 (patch)
tree17ac0bc9b0823f29bf61b53980ff8a71aad37670 /core/org.eclipse.cdt.core
parent76b7b643071657af67a376053863b6fb0e07bcd4 (diff)
downloadorg.eclipse.cdt-1ea6dac9afbde9875a4da8b25c9403eeab333ab7.tar.gz
org.eclipse.cdt-1ea6dac9afbde9875a4da8b25c9403eeab333ab7.tar.xz
org.eclipse.cdt-1ea6dac9afbde9875a4da8b25c9403eeab333ab7.zip
Bug 549078 - ArrayOutOfBoundsException in AbstractIndexerTask.IndexFileContent.merge()
Diffstat (limited to 'core/org.eclipse.cdt.core')
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java
index afa227f6f5..5ceb609ee0 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java
@@ -283,10 +283,10 @@ public abstract class AbstractIndexerTask extends PDOMWriter {
int ioffset = getOffset(includes, i);
int moffset = getOffset(macros, m);
for (int k = 0; k < merged.length; k++) {
- if (ioffset <= moffset) {
+ if (ioffset <= moffset && i < includes.length) {
merged[k] = includes[i];
ioffset = getOffset(includes, ++i);
- } else {
+ } else if (m < macros.length) {
merged[k] = macros[m];
moffset = getOffset(macros, ++m);
}

Back to the top