1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-23 08:55:25 +02:00

Bug 384780 - No error is reported if a directory is specified as program

path.
This commit is contained in:
Mikhail Khodjaiants 2012-07-10 16:16:03 -04:00
parent 9dbd7f7213
commit e19147b554

View file

@ -498,6 +498,11 @@ public class CMainTab extends CAbstractMainTab {
// Notice that we don't check if exePath points to a valid executable since such
// check is too expensive to be done on the UI thread.
// See "https://bugs.eclipse.org/bugs/show_bug.cgi?id=328012".
// We only verify that the program path represents a file.
if (!exePath.toFile().isFile()) {
setErrorMessage(fPreviouslyCheckedProgramErrorMsg = LaunchMessages.CMainTab_Selection_must_be_file);
return (fPreviouslyCheckedProgramIsValid = false);
}
}
}