Greetings to everybody!
I don't know whether this is the right place to post this topic since it concerns both
servlets and j2me. If this post does not belong here please place it where it does!
I've recently began developing j2me applications, and lastly I've written a Midlet that transmits a png image file to a server.
The server side software is based on apache
tomcat 6.
I've installed tomcat on two pcs. One laptop with windows where I do my developing, and one linux machine (ubuntu to be exact) with static ip which is designated to be the server when my project ends. I've placed the same web.xml,context.xml,server.xml and tomcat-users.xml to both servers so I assume that they are configured exactly the same.
I've written a very simple servlet that receives the Image through an input stream. The code is the following :
When I execute my Midlet through the Wireless Toolkit emulator and I target my request to the tomcat that runs on localhost (the windows machine) the application works perfectly.
I've transfered this servlet to the linux machine, changed the following code
to
recompiled it there and tried it out, but the servlet now does not work.
A image.png file is created but it is empty. After running some tests I discovered that this loop
is never entered when it runs on the linux machine. Can anyone figure out why the InputStream receives nothing when ran on the pc with the static ip, but runs perfectly on the localhost? The Mildet is the same on both occasions.
Any help would be greatly appreciated! I hope you haven't slept half way through this post!
Thank you a lot and in advance for your reply!