From 10356a14966b1f6270f3e9774cf97989e02943f4 Mon Sep 17 00:00:00 2001 From: Denys Almazov Date: Tue, 17 Oct 2023 20:43:55 +0300 Subject: [PATCH] fix: fixed parsing exception --- .../com/espressif/idf/core/build/IDFBuildConfiguration.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bundles/com.espressif.idf.core/src/com/espressif/idf/core/build/IDFBuildConfiguration.java b/bundles/com.espressif.idf.core/src/com/espressif/idf/core/build/IDFBuildConfiguration.java index c0545fe50..7fae0dfcb 100644 --- a/bundles/com.espressif.idf.core/src/com/espressif/idf/core/build/IDFBuildConfiguration.java +++ b/bundles/com.espressif.idf.core/src/com/espressif/idf/core/build/IDFBuildConfiguration.java @@ -1245,6 +1245,10 @@ private IFile getFileForCMakePath(String sourceFileName, IProject project) pathtolookfor = getIdfToolsPath(); startIndex = sourceFile.indexOf(pathtolookfor); } + if (startIndex == -1) // source file still not found means it was part of another esp-idf + { + return null; + } String relativePath = sourceFile.substring(startIndex + pathtolookfor.length() + 1); IPath projectPath = getComponentsPath().append(relativePath);