emulation on host: fix for latest changes in dnsserver by d-a-v · Pull Request #8559 · esp8266/Arduino (original) (raw)
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Conversation8 Commits2 Checks0 Files changed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})
@@ -1,5 +1,7 @@ |
---|
#ifndef DNSServer_h |
#define DNSServer_h |
#include |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
future-proofing, I tried adding DNSServer/examples/DNSServer to host test script, but I see valgrind error in UDP code 🤷
something to note
@@ -1,5 +1,7 @@ |
---|
#ifndef DNSServer_h |
#define DNSServer_h |
#include |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
future-proofing, I tried adding DNSServer/examples/DNSServer to host test script, but I see valgrind error in UDP code 🤷
something to note
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a line number to go with that?
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also mocking. ~DNSServer -> ~WiFiUDP -> UdpContext.disconnect() tries to delete std::map entry, which may or may not be already destroyed (?).
Not related to the DNSServer, but to the way UDP is organized there.
With this change:
--- a/libraries/DNSServer/examples/DNSServer/DNSServer.ino +++ b/libraries/DNSServer/examples/DNSServer/DNSServer.ino @@ -1,5 +1,5 @@ -#include <ESP8266WiFi.h> #include <DNSServer.h> +#include <ESP8266WiFi.h> #include <ESP8266WebServer.h>
This happens:
C++ ...libraries/DNSServer/examples/DNSServer/DNSServer.ino.cpp.o
In file included from ./../../libraries/DNSServer/examples/DNSServer//DNSServer.ino:1,
from ...libraries/DNSServer/examples/DNSServer/DNSServer.ino.cpp:1:
../../libraries/DNSServer/src/DNSServer.h:113:10: error: ‘unique_ptr’ in namespace ‘std’ does not name a template type
113 | std::unique_ptr<DNSS_REQUESTER[]> _que;
| ^~~~~~~~~~
../../libraries/DNSServer/src/DNSServer.h:4:1: note: ‘std::unique_ptr’ is defined in header ‘<memory>’; did you forget to ‘#include <memory>’?
3 | #include <WiFiUdp.h>
+++ |+#include <memory>
4 |
d-a-v deleted the dnserveronhost branch
hasenradball pushed a commit to hasenradball/Arduino that referenced this pull request