Răsfoiți Sursa

#IQRV #comment [Other] 新增 libRestfulFunc 优化

gifur 3 ani în urmă
părinte
comite
9f80e2ea7a

+ 1 - 1
Other/libRestfulFunc/RestfulFunc.h

@@ -28,6 +28,6 @@
 * -2:超时
 * -3:地址不符合规范
 */
-RESTFULFUNC_API int HttpProbe(const std::string& url, std::string& out_msg, uint32_t wait_max_secs = 30);
+RESTFULFUNC_API int HttpProbe(const std::string& url, std::string& out_msg, uint32_t wait_max_secs = (uint32_t)-1);
 
 #endif //_OTHER_RESFULFUNCEXPORT_HEADER_

+ 7 - 0
Other/libRestfulFunc/test/testHttpProbe.cpp

@@ -2,6 +2,13 @@
 #include <catch2.hpp>
 #include "RestfulFunc.h"
 
+TEST_CASE("test http test 406 probe", "[probe0]")
+{
+    std::string msg;
+    REQUIRE(HttpProbe("http://55.11.54.115:82/index.html", msg) > 0);
+    std::cout << msg << std::endl;
+}
+
 TEST_CASE("test http connected probe", "[probe1]")
 {
     std::string msg;

+ 1 - 0
addin/cmake/DependencyConanFiles.cmake

@@ -192,6 +192,7 @@ set(AARCH64_USELESS_LIBRARY_FILE_NAMES
 	libX11-xcb.la
 	libX11-xcb.so
 	libX11-xcb.so.1.0.0
+	libcpprest.so
 	# libyuv.so
 	localinfo
 	opj_compress