From 37db1074b6fa5aa81871822d3e8e16a30f2ebfb1 Mon Sep 17 00:00:00 2001
From: Danny Auble <da@schedmd.com>
Date: Thu, 7 Jan 2016 10:43:06 -0800
Subject: [PATCH] Only look at the first argument of the script command lines
 opts to see if it is a script or not.

---
 contribs/openlava/bsub.pl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/contribs/openlava/bsub.pl b/contribs/openlava/bsub.pl
index 14f32812c3f..afe810382b7 100644
--- a/contribs/openlava/bsub.pl
+++ b/contribs/openlava/bsub.pl
@@ -145,7 +145,7 @@ if (!$script) {
 	}
 }
 
-if (_check_script($script)) {
+if (_check_script($ARGV[0])) {
 	$command = $base_command = "$sbatch";
 } else {
 	$command = $base_command = "$srun";
-- 
GitLab