[Arakhnę-Dev] [154] Replies false in isWindowNativeFilename() when given filename is null or empty.

[ Thread Index | Date Index | More arakhne.org/dev Archives ]


Revision: 154
Author:   galland
Date:     2010-05-20 16:14:12 +0200 (Thu, 20 May 2010)
Log Message:
-----------
Replies false in isWindowNativeFilename() when given filename is null or empty.

Modified Paths:
--------------
    trunk/arakhneVmutils/java/src/main/java/org/arakhne/vmutil/FileSystem.java

Modified: trunk/arakhneVmutils/java/src/main/java/org/arakhne/vmutil/FileSystem.java
===================================================================
--- trunk/arakhneVmutils/java/src/main/java/org/arakhne/vmutil/FileSystem.java	2010-05-18 07:06:12 UTC (rev 153)
+++ trunk/arakhneVmutils/java/src/main/java/org/arakhne/vmutil/FileSystem.java	2010-05-20 14:14:12 UTC (rev 154)
@@ -1755,8 +1755,7 @@
 	 */
 	public static boolean isWindowsNativeFilename(String filename) {
 		String fn = extractLocalPath(filename);
-		assert(fn!=null);
-		if (fn.length()==0) return false;
+		if (fn==null || fn.length()==0) return false;
 		Pattern pattern = Pattern.compile(WINDOW_NATIVE_FILENAME_PATTERN);
 		Matcher matcher = pattern.matcher(fn);
 		return matcher.find();


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/