Thank you for your help, in my case is a Nexus One v2.3.6 (a bit old)
and I have been doing a bit more of testing, this is the logcat when
the access point change:


03-29 08:33:12.890 I/wpa_supplicant(  934): CTRL-EVENT-DISCONNECTED -
Disconnect event - remove keys
03-29 08:33:12.890 V/WifiMonitor(   96): Event [CTRL-EVENT-
DISCONNECTED - Disconnect event - remove keys]
03-29 08:33:12.890 V/WifiStateTracker(   96): New network state is
DISCONNECTED
03-29 08:33:12.900 I/wpa_supplicant(  934): CTRL-EVENT-STATE-CHANGE
id=1 state=0 BSSID=00:00:00:00:00:00
03-29 08:33:12.900 V/WifiMonitor(   96): Event [CTRL-EVENT-STATE-
CHANGE id=1 state=0 BSSID=00:00:00:00:00:00]
03-29 08:33:12.900 V/WifiStateTracker(   96): Changing supplicant
state: COMPLETED ==> DISCONNECTED
03-29 08:33:12.900 D/ARIADNA (  606): connectionChangeReceiver -
SUPPLICANT_STATE_CHANGED_ACTION
03-29 08:33:12.900 D/ARIADNA (  606): Stop Socket and start
buffering...

The problem is that the last message received by the server is on
08:32:54 after that 10 messages are sended but not received (before
the broadcast received).

¿Is there any way to detect if the message has arrive to the server?
¿Other way to test connectivity or test the server? this is the way I
implement the socket:

                sock = new Socket();
                sock.bind(null);
                InetSocketAddress isa = new
InetSocketAddress(serverIPAddress,serverPort);
                sock.connect(isa, conectionTimeOut);
                sock.setKeepAlive(true);
                isR = new InputStreamReader(sock.getInputStream(), "UTF8");
                reader = new BufferedReader(isR);
                out = new BufferedWriter(new
OutputStreamWriter(sock.getOutputStream(), "UTF8"));

Thank you so much







On 29 mar, 00:52, Irfan Sheriff <isher...@gmail.com> wrote:
> >  It would be good to know if there are devices beyond ICS that still have
> > issues around not resetting socket connections when a network goes away.
>
> > Beyond ICS? I don't know what this means.
>
> > My "flagship" Galaxy Nexus still hasn't received 4.0.3.
>
> > And what do you mean by "would be good to know"?
>
> > Should we, developers, and our users, moonlight as Android's test
> > department?
>
> I think we dont have a CTS around this behavior. I will look at filing a
> bug internally for this to ensure things remain sane going forward.
>
> Thanks
>
>
>
>
>
>
>
>
>
> > Ideally, apps should not have to listen to any broadcasts to handle
> > network switches and should get resets on an existing socket.
>
> > Not ideally -- really -- apps are supposed to work on more than the 1.6%
> > of devices with ICS.
>
> > And "beyond ICS" - what portion of the market is that, at this time,
> > exactly?
>
> > -- K
>
> > Irfan
>
> >  --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to android-developers@googlegroups.com
> > To unsubscribe from this group, send email to
> > android-developers+unsubscr...@googlegroups.com
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to