summaryrefslogtreecommitdiffstats
path: root/org.aspectj.ajdt.core
diff options
context:
space:
mode:
authoraclement <aclement>2005-06-01 16:12:58 +0000
committeraclement <aclement>2005-06-01 16:12:58 +0000
commita675b659cdc4da45383551e75c9472556c095f94 (patch)
tree517b6d09df98b8fbf5cd20752ece523924cb677e /org.aspectj.ajdt.core
parentefecc457e9a44d9f26454523af0b6c48b917b4b7 (diff)
downloadaspectj-a675b659cdc4da45383551e75c9472556c095f94.tar.gz
aspectj-a675b659cdc4da45383551e75c9472556c095f94.zip
Patch for 81846: Submitted by Attila Lendvai. Seems to just be hiding a problem where we report errors on empty lines though ?!?
Diffstat (limited to 'org.aspectj.ajdt.core')
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/EclipseAdapterUtils.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/EclipseAdapterUtils.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/EclipseAdapterUtils.java
index e2c296245..0b0deae50 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/EclipseAdapterUtils.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/EclipseAdapterUtils.java
@@ -80,8 +80,8 @@ public class EclipseAdapterUtils {
char c;
//remove all SPACE and TAB that begin the error message...
int trimLeftIndex = 0;
- while (((c = extract[trimLeftIndex++]) == TAB) || (c == SPACE)) {
- };
+ while ( (((c = extract[trimLeftIndex++]) == TAB) || (c == SPACE)) && trimLeftIndex<extract.length ) { };
+ if (trimLeftIndex>=extract.length) return new String(extract)+"\n";
System.arraycopy(
extract,
trimLeftIndex - 1,