java.lang.NullPointerException: java.lang.String.getBytes(

Nick Johnson freebsd at
Mon Dec 18 20:59:56 PST 2006

Just a guess, but there's a version of getBytes that takes a character set 
name as an argument, which would probably throw a NullPointerException in 
the event that the argument you passsed it was a null string.

Take a look at 
and see if there's a chance that your HttpServletWrapper line 346 could be 
passing null for the character set name.


On Mon, 18 Dec 2006, Marc G. Fournier wrote:

> Hash: SHA1
> Hate to ask when I don't believe I have near enough information, but my 
> knowledge o Java is so small that I don't even know where to begin debugging ...
> Have a client running an application, that, when run on an older FreeBSD 4.x 
> machine, with jdk from ports, ran great ...
> Recently, upgraded them to FreeBSD 6.x, with Diablo, and from a 32bit server to 
> a 64bit server, and now whenever they submit certain forms on the site, it 
> generates the following error:
> java.lang.NullPointerException
> 	java.lang.String.getBytes(
> 	org.dataisland.wrapper.servlet.HttpServletWrapper.streamDocument(
> 	org.dataisland.wrapper.servlet.HttpServletWrapper.serveDataIsland(
> 	org.dataisland.wrapper.servlet.HttpServletWrapper.service(
> 	javax.servlet.http.HttpServlet.service(
> 	org.opencommerce.iface.servlet.filter.Secure.doFilter(
> The site *appears* to work fine otherwise ... its an e-commerce site, and I can 
> add products to my shopping cart, search the database, etc ... but, for 
> instance, if I try to update my profile, or they try and update prices, the 
> above happens ...
> Can someone suggest what, if anything, I can do to debug this a bit more 
> intelligently?
> Thanks ..
> - ----
> Marc G. Fournier           Hub.Org Networking Services (
> Email . scrappy at                              MSN . scrappy at
> Yahoo . yscrappy               Skype:        ICQ . 7615664
> Version: GnuPG v1.4.5 (FreeBSD)
> iD4DBQFFh2Ea4QvfyHIvDvMRAkwcAJUWlJ2BJwPiCSAJyejiwM7+/cRkAJ4ltcH7
> CSsBMrwm9y9o4qJiIKPy+A==
> =M9q+
> _______________________________________________
> freebsd-java at mailing list
> To unsubscribe, send any mail to "freebsd-java-unsubscribe at"

When you're a kid, they tell you it's all grow up, get a job, get married,
get a house, have a kid, and that's it.  No, the truth is the world is so
much stranger than that.  It's so much darker, and so much madder.
And so much better.
  -- Elton, Doctor Who, "Love and Monsters"
This message has been brought to you by Nick Johnson 2.1 and the number 6.

More information about the freebsd-java mailing list