axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yanlun Ma" <Yanlun...@businessobjects.com>
Subject RE: [axis2] IOException when rampart1.0 was deployed.
Date Tue, 09 May 2006 21:57:28 GMT
In following code of org.apache.axis2.deployment.util.Utils, the
File.createTempFile("axis2", entryName.substring(4)); got IO exception
and said "Invalid path".  Add the line "new
File(System.getProperty("java.io.tmpdir")).mkdirs();" can solve this
problem.
 
Please take a look,
 
See http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4847239  for the
proposed walkaround.
 
Thanks,
 
Yanlun
 
 
                if ((entryName != null) &&
entryName.toLowerCase().startsWith("lib/")
                        && entryName.toLowerCase().endsWith(".jar")) {
                    byte data[] = new byte[2048];
                    int count;
                    new
File(System.getProperty("java.io.tmpdir")).mkdirs();
                    File f = File.createTempFile("axis2",
entryName.substring(4));
                    f.deleteOnExit();
                    FileOutputStream out = new FileOutputStream(f);
                    while ((count = zin.read(data, 0, 2048)) != -1) {
                        out.write(data, 0, count);
                    }
                    out.close();
                    array.add(f.toURL());
                }

Mime
View raw message