You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by sc...@apache.org on 2002/01/14 17:12:54 UTC
cvs commit: xml-axis/java/src/org/apache/axis/utils JavapUtils.java
scheu 02/01/14 08:12:54
Modified: java/src/org/apache/axis/utils JavapUtils.java
Log:
make sure javap has the proper classpath
Revision Changes Path
1.2 +13 -1 xml-axis/java/src/org/apache/axis/utils/JavapUtils.java
Index: JavapUtils.java
===================================================================
RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/utils/JavapUtils.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- JavapUtils.java 3 Jan 2002 20:33:43 -0000 1.1
+++ JavapUtils.java 14 Jan 2002 16:12:54 -0000 1.2
@@ -166,9 +166,21 @@
Vector cachedInfo = null;
BufferedReader br = null;
try {
+ String cp = System.getProperty("java.class.path");
+
Runtime rt = Runtime.getRuntime();
// The -l option is used to access the local variables.
- Process pr = rt.exec("javap -private -l " + cls.getName());
+ Process pr = rt.exec("javap -classpath " + cp + " -private -l " + cls.getName());
+
+ //BufferedReader ebr = new BufferedReader(new InputStreamReader(pr.getErrorStream()));
+ //if (ebr != null) {
+ // String line = ebr.readLine();
+ // System.out.println(line);
+ // while (line != null) {
+ // line = ebr.readLine();
+ // }
+ //}
+
br = new BufferedReader(new InputStreamReader(pr.getInputStream()));
if (br != null) {
cachedInfo = new Vector();