A fork of the original interface for OS/2. Features a correctly-implemented recv (but retains the old behavior via recv2).

Dependencies:   BufferedSerial

Dependents:   weather_clock weather_clock

Revision:
23:de9221771e96
Parent:
22:c4360e61486a
Child:
27:9c6cefc12f0c
--- a/Socket/UDPSocket.cpp	Tue Dec 02 16:02:21 2014 +0000
+++ b/Socket/UDPSocket.cpp	Mon Dec 08 00:53:07 2014 +0000
@@ -95,15 +95,14 @@
     while (time < _timeout) {
 
         nb_available = wifi->readable();
-        for (int i = 0; i < min(nb_available, length); i++) {
+        //for (int i = 0; i < min(nb_available, length); i++) {
+        for (int i = 0; i < min(nb_available, (length-idx)); i++) {
             buffer[idx] = wifi->getc();
             idx++;
         }
-
         if (idx == length) {
             break;
         }
-        
         time = tmr.read_ms();
     }
     readEndpoint(remote);