mirror of
https://github.com/esphome/esphome.git
synced 2026-09-25 05:54:01 +00:00
Merge remote-tracking branch 'origin/log-unsupported-udp-socket' into integration
This commit is contained in:
@@ -680,6 +680,11 @@ class LWIPRawListenImpl final : public LWIPRawImpl {
|
||||
};
|
||||
|
||||
std::unique_ptr<Socket> socket(int domain, int type, int protocol) {
|
||||
if (type != SOCK_STREAM) {
|
||||
ESP_LOGE(TAG, "UDP sockets not supported on this platform, use WiFiUDP");
|
||||
errno = EPROTOTYPE;
|
||||
return nullptr;
|
||||
}
|
||||
auto *pcb = tcp_new();
|
||||
if (pcb == nullptr)
|
||||
return nullptr;
|
||||
|
||||
Reference in New Issue
Block a user