Blame SOURCES/environment-modules-3.2.10-ignore-nested-dirs.patch

5352b7
diff -up modules-3.2.9/locate_module.c.SourceVers modules-3.2.9/locate_module.c
5352b7
--- modules-3.2.9/locate_module.c.SourceVers	2013-06-30 17:23:01.451210176 +0200
5352b7
+++ modules-3.2.9/locate_module.c	2013-06-30 17:24:16.963201645 +0200
5352b7
@@ -1194,6 +1194,11 @@ int SourceVers( Tcl_Interp *interp, char
5352b7
 		 **  The version has been specified in the
5352b7
 		 **  '.version' file. Set up the result code
5352b7
 		 **/
5352b7
+		/* version can be only located in the current directory */
5352b7
+		if (strrchr(version, '/')) {
5352b7
+			ErrorLogger( ERR_BADMODNAM, LOC, version, NULL);
5352b7
+			return( TCL_ERROR);
5352b7
+		}
5352b7
 		/* for deep modulefile dirs ... just use lowest part */
5352b7
 		if (!(modname = (char*) strrchr( name, '/'))) {
5352b7
 			modname = name;