From 8768d0f4c4684ac806e072bbb1a6bd3882d0ade6 Mon Sep 17 00:00:00 2001 From: Alain Magloire Date: Thu, 14 Nov 2002 03:19:05 +0000 Subject: [PATCH] check the validity of the column i.e. has to be a number. --- .../org/eclipse/cdt/internal/errorparsers/GCCErrorParser.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/org.eclipse.cdt.core/src/org/eclipse/cdt/internal/errorparsers/GCCErrorParser.java b/core/org.eclipse.cdt.core/src/org/eclipse/cdt/internal/errorparsers/GCCErrorParser.java index ea95fd76fbc..0c9f6032431 100644 --- a/core/org.eclipse.cdt.core/src/org/eclipse/cdt/internal/errorparsers/GCCErrorParser.java +++ b/core/org.eclipse.cdt.core/src/org/eclipse/cdt/internal/errorparsers/GCCErrorParser.java @@ -64,8 +64,9 @@ public class GCCErrorParser implements IErrorParser { /* Then check for the column */ int thirdColon= line.indexOf(':', secondColon + 1); if (thirdColon != -1) { + String columnNumber = line.substring(secondColon + 1, thirdColon); try { - col = Integer.parseInt(lineNumber); + col = Integer.parseInt(columnNumber); } catch (NumberFormatException e) { } }