I'm writing an app that does frequent HTTP requests. On the 7650 I've encountered a problem with the app freezing after a while when trying to make a connection. This always happens when I call HttpConnection.getResponseCode(), which shifts the connection into the "connected" mode. I want the MIDlet to throw some kind of time out Exception if it spends too much time on this method. I tried using Connector.open(url,Connector.READ,true) for this, but it isn't helping.
Is there anyway to achieve this timeout, because write now the app just freezes, and there is nothing I can do about it. With a timeout exception I could at least handle the error somehow.