diff options
author | michelou <michelou@epfl.ch> | 2007-06-04 16:53:55 +0000 |
---|---|---|
committer | michelou <michelou@epfl.ch> | 2007-06-04 16:53:55 +0000 |
commit | a31e57a3e70fd56ee94be39e9ca831ca1972b4eb (patch) | |
tree | 63de84d8620270d8c368dfdeb7fc35e2101dc998 | |
parent | 26400b7b32cb6b3d004e35de033f7152e886ff71 (diff) | |
download | scala-a31e57a3e70fd56ee94be39e9ca831ca1972b4eb.tar.gz scala-a31e57a3e70fd56ee94be39e9ca831ca1972b4eb.tar.bz2 scala-a31e57a3e70fd56ee94be39e9ca831ca1972b4eb.zip |
fixed methods 'urls'
-rw-r--r-- | src/compiler/scala/tools/nsc/MainGenericRunner.scala | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/compiler/scala/tools/nsc/MainGenericRunner.scala b/src/compiler/scala/tools/nsc/MainGenericRunner.scala index 53ae8cc793..c5b903066f 100644 --- a/src/compiler/scala/tools/nsc/MainGenericRunner.scala +++ b/src/compiler/scala/tools/nsc/MainGenericRunner.scala @@ -102,10 +102,12 @@ object MainGenericRunner { catch { case e => Console.println(e); None } def urls(specs: String): List[URL] = { - val urls = for ( - spec <- specs.split(" ").toList; - val url = specToURL(spec); if !url.isEmpty - ) yield url.get + val urls = + if (specs == null || specs.length == 0) Nil + else for ( + spec <- specs.split(" ").toList; + val url = specToURL(spec); if !url.isEmpty + ) yield url.get if (!urls.isEmpty && (System.getSecurityManager == null)) { // Here we require a security manager to be present ! // Security permissions are defined in a user-defined |