Thank you for taking the time to put this diff Roger,
Daniel does this make sense? if so please add it asap

marc


|-----Original Message-----
|From: [EMAIL PROTECTED]
|[mailto:[EMAIL PROTECTED]]On Behalf Of Roger Spreen
|Sent: Friday, November 10, 2000 2:40 AM
|To: [EMAIL PROTECTED]
|Subject: [jBoss-User] Null pointer needs to be checked in
|J2eeDeployer.java
|
|
|Hi, folks:
|
|This is my first posting to this list, and I'm a relatively new Jboss user,
|so I hope this posting is appropriate.  Jboss is great stuff, so my
|congratulations to the team!
|
|== My request: add a check for null in
|org/jboss/deployment/J2eeDeployer.java, line 502.
|
|== The change in detail:
|change:
|
|   Manifest mf = new JarFile (localUrl.getFile ()).getManifest ();
|   addCommonLibs( _d, mf, _source);
|
|to:
|   Manifest mf = new JarFile (localUrl.getFile ()).getManifest ();
|   if (mf != null)
|      addCommonLibs( _d, mf, _source);
|
|== Reason:
|The "addCommonLibs" method was just added recently, after PROD_BETA_3, with
|the intention of getting the classpath information out of the
|manifest file.
|Inside the "addCommonLibs" method, there is a check for null on the
|classpath attribute retrieved from "mf", but there is no check on whether
|"mf" itself is null.
|
|Without this null check, you get a nasty deployment failure (with a
|nullpointer exception) if your jar does not include a manifest file (or if
|it contains an empty manifest file).  While it's a good idea to have a
|manifest, I'm not sure it's mandatory, and there are certain development
|environments (notably CodeWarrior) where it is more typical not to have one
|(no flames about CodeWarrior please, I know them all already :-)
|Thus, this
|nullpointer failure prevents all our bean jars from deploying.  An
|alternative solution is to put the nullpointer check inside addCommonLibs.
|
|My thanks in advance for making this change!
|
|Cheers,
|  Roger
|
|
|
|
|--
|--------------------------------------------------------------
|To subscribe:        [EMAIL PROTECTED]
|To unsubscribe:      [EMAIL PROTECTED]
|Problems?:           [EMAIL PROTECTED]
|
|



--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to