[jboss-svn-commits] JBL Code SVN: r29684 - labs/jbosstm/workspace/adinn/byteman/trunk/bin.

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Tue Oct 20 06:31:18 EDT 2009


Author: adinn
Date: 2009-10-20 06:31:18 -0400 (Tue, 20 Oct 2009)
New Revision: 29684

Modified:
   labs/jbosstm/workspace/adinn/byteman/trunk/bin/bmjava.sh
Log:
corrected script load flag from -r to -l -- fxes for BYTEMAN-51

Modified: labs/jbosstm/workspace/adinn/byteman/trunk/bin/bmjava.sh
===================================================================
--- labs/jbosstm/workspace/adinn/byteman/trunk/bin/bmjava.sh	2009-10-20 10:28:22 UTC (rev 29683)
+++ labs/jbosstm/workspace/adinn/byteman/trunk/bin/bmjava.sh	2009-10-20 10:31:18 UTC (rev 29684)
@@ -53,14 +53,14 @@
 usage()
 {
 cat <<EOF
-usage: bmjava [-r rulescript | -b bootjar | -s sysjar | -nl | -nb ]* [--] javaargs
+usage: bmjava [-l rulescript | -b bootjar | -s sysjar | -nl | -nb ]* [--] javaargs
 
 terms enclosed between [ ] are optional
 terms separated by | are alternatives
 a * means zero or more occurences
 
-  -r  pass the file whose name follows this flag to the agent as
-      a rule script
+  -l  pass the file whose name follows this flag to the agent as
+      a rule script to be loaded during startup
 
   -b  pass the file whose name follows this flag to the agent as
       a jar to be added to the bootstrap classpath
@@ -122,7 +122,7 @@
 echo "\$# == $#" 
 while [ $# -ge 1 -a "${1#-*}" != "$1" ]
 do
-    if [ "$1" == "-r" -a $# -ge 2 ]; then
+    if [ "$1" == "-l" -a $# -ge 2 ]; then
 	if [ -r "$2" ]; then
 	    AGENT_OPTS="${AGENT_OPTS},script:$2"
 	    shift;
@@ -150,14 +150,17 @@
 	    exit
 	fi
     elif [ "$1" == "-nl" ]; then
-	LISTENER=0
-	shift;
+	    LISTENER=0
+	    shift;
     elif [ "$1" == "-nb" ]; then
-	BYTEMAN_BOOT_JAR=0
-	shift;
+	    BYTEMAN_BOOT_JAR=0
+	    shift;
     elif [ "$1" == "--" ]; then
-	shift;
-	break;
+	    shift;
+	    break;
+	else
+	    # unrecognised option -- must be start of javaargs
+	    break
     fi
 done
 



More information about the jboss-svn-commits mailing list