MCPcopy Create free account
hub / github.com/BlueAndi/Pixelix / onError

Method onError

lib/AsyncHttpClient/src/AsyncHttpClient.cpp:747–770  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

745}
746
747void AsyncHttpClient::onError(int8_t error)
748{
749 const char* errorDescription = errorToStr(error);
750
751 if (nullptr != errorDescription)
752 {
753 LOG_WARNING("Error occurred: %d - %s", error, errorDescription);
754 }
755 else
756 {
757 const int8_t HOST_IS_UNREACHABLE = 113; /* https://github.com/yubox-node-org/AsyncTCPSock/issues/13 */
758
759 LOG_WARNING("Error occurred: %d", error);
760
761 if (HOST_IS_UNREACHABLE == error)
762 {
763 LOG_WARNING("Host is unreachable.");
764 }
765 }
766
767 m_isError = true;
768 notifyError();
769 disconnect();
770}
771
772void AsyncHttpClient::onData(const uint8_t* data, size_t len)
773{

Callers 2

AsyncHttpClientMethod · 0.45
~AsyncHttpClientMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected