title: Android UdpClient broadcast listener receives only after locking and unlocking the phone
body: <p>In spite the subject - this is an android question.
  I'm relatively new to Android architecture and I'm working with c# xamarin over visual studio. I have a UdpClient class which works as expected receiving broadcast messages from Wifi.
  <strong>I have a bug in the program</strong> - I noticed if I disconnect from my wifi network and reconnect - the new UdpClient doesn't receive and process any broadcast packets (it does receive unicast).</p>
  <p>Found out after days of investigation that when I lock the phone and unlock it when the Wifi is connected, suddenly everything works perfectly. My hunch tells me that way I'm resetting something in the Android OS and that I could somehow do it without locking/unlocking the phone.</p>
  <p>I have created a broadcast receiver to track the network changes but I cannot see any difference between the values of a network before and after lock/unlock.
  Any ideas? someone already solved it somehow?</p>
  <p>Thanks</p>