Author: vyemialyanchyk
Date: 2009-02-06 11:54:21 -0500 (Fri, 06 Feb 2009)
New Revision: 13519
Modified:
trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/launch/PathHelper.java
Log:
JBIDE-3768
Modified:
trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/launch/PathHelper.java
===================================================================
---
trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/launch/PathHelper.java 2009-02-06
16:40:56 UTC (rev 13518)
+++
trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/launch/PathHelper.java 2009-02-06
16:54:21 UTC (rev 13519)
@@ -103,9 +103,14 @@
IPath path = pathOrNull(resolve(strpath));
- if (checkFilesystem) {
- if (path != null && new File(path.toOSString()).exists()) {
- return null;
+ if (checkFilesystem && path != null) {
+ File file = new File(path.toOSString());
+ if (file.exists()) {
+ if (file.isDirectory()) {
+ return null;
+ }
+ String out = NLS.bind(HibernateConsoleMessages.PathHelper_not_directory, path);
+ return out;
}
}