Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: DnsClient.cpp
- Revision:
- 16:269f652b4d0b
- Parent:
- 15:53715cc81c63
- Child:
- 18:8d5738a6646e
--- a/DnsClient.cpp Sat Sep 07 17:42:42 2019 +0000
+++ b/DnsClient.cpp Fri Jun 05 15:12:21 2020 +0000
@@ -7,6 +7,7 @@
#include "DnsClient.h"
#include <string.h>
#include "mbed.h"
+#include "mbed_version.h"
#define SOCKET_NONE 255
@@ -284,7 +285,11 @@
while (iUdp.parsePacket() <= 0) {
if (timer.read() > aTimeout)
return TIMED_OUT;
+#if MBED_MAJOR_VERSION == 2
wait_ms(50);
+#else
+ thread_sleep_for(50);
+#endif
}
// We've had a reply!