diff --git a/src/util/http_sender.cpp b/src/util/http_sender.cpp index ea29f29..baf3c7e 100644 --- a/src/util/http_sender.cpp +++ b/src/util/http_sender.cpp @@ -275,6 +275,10 @@ int HttpSender::SendRequest( SDK_LOG_INFO("Request canceled by user"); *err_msg = "Request canceled by user"; return -1; + } catch (Poco::URISyntaxException& ex) { + SDK_LOG_ERR("url:%s URISyntaxException:%s", url_str.c_str(), ex.displayText().c_str()); + *err_msg = "url:" + url_str + " URISyntaxException:" + ex.displayText(); + return -1; } catch (const std::exception& ex) { SDK_LOG_ERR("Exception:%s, errno=%d", std::string(ex.what()).c_str(), errno); @@ -492,6 +496,10 @@ int HttpSender::SendRequest( SDK_LOG_INFO("Request canceled by user"); *err_msg = "Request canceled by user"; return -1; + } catch (Poco::URISyntaxException& ex) { + SDK_LOG_ERR("url:%s URISyntaxException:%s", url_str.c_str(), ex.displayText().c_str()); + *err_msg = "url:" + url_str + " URISyntaxException:" + ex.displayText(); + return -1; } catch (const std::exception& ex) { SDK_LOG_ERR("Exception:%s, errno=%d", std::string(ex.what()).c_str(), errno);