Skip to content

Commit a6be8c7

Browse files
committed
Reverting part of commit ff7c964 (Add
ability to do jetty:run in eclipse). This change breaks the ability to upload scripts to XenServer (and possibly other places). Needs some investigation before enabling this again.
1 parent 2ba09d8 commit a6be8c7

1 file changed

Lines changed: 9 additions & 6 deletions

File tree

utils/src/com/cloud/utils/script/Script.java

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -340,15 +340,18 @@ public static String findScript(String path, String script) {
340340
File file = null;
341341
if (url != null) {
342342
file = new File(url.getFile());
343+
s_logger.debug("Absolute path = " + file.getAbsolutePath());
343344
return file.getAbsolutePath();
344345
}
345346

346-
url = Script.class.getClassLoader().getResource(path);
347-
if (url != null) {
348-
file = new File(url.getFile());
349-
return file.getAbsolutePath();
350-
}
351-
347+
/* url = Script.class.getClassLoader().getResource(path);
348+
* s_logger.debug("Classpath resource: " + url);
349+
* if (url != null) {
350+
* file = new File(url.getFile());
351+
* s_logger.debug("Absolute path = " + file.getAbsolutePath());
352+
* return file.getAbsolutePath();
353+
* }
354+
*/
352355
if (path.endsWith(File.separator)) {
353356
path = path.substring(0, path.lastIndexOf(File.separator));
354357
}

0 commit comments

Comments
 (0)