scripts : use official split.py for cpp-httplib (#19588)
* scripts : use official split.py for cpp-httplib Using the official script is safer and ensures the generated code aligns with the library's standards. Signed-off-by: Adrien Gallouët <angt@huggingface.co> * Catch generic errors Signed-off-by: Adrien Gallouët <angt@huggingface.co> * Allow print() Signed-off-by: Adrien Gallouët <angt@huggingface.co> * Ensure robust cleanup Signed-off-by: Adrien Gallouët <angt@huggingface.co> --------- Signed-off-by: Adrien Gallouët <angt@huggingface.co>
This commit is contained in:
Vendored
+1
-2
@@ -1,7 +1,6 @@
|
||||
#include "httplib.h"
|
||||
namespace httplib {
|
||||
|
||||
|
||||
/*
|
||||
* Implementation that will be part of the .cc file if split into .h + .cc.
|
||||
*/
|
||||
@@ -1219,7 +1218,7 @@ int close_socket(socket_t sock) {
|
||||
#endif
|
||||
}
|
||||
|
||||
template <typename T> inline ssize_t handle_EINTR(T fn) {
|
||||
template <typename T> ssize_t handle_EINTR(T fn) {
|
||||
ssize_t res = 0;
|
||||
while (true) {
|
||||
res = fn();
|
||||
|
||||
Vendored
-1
@@ -3336,7 +3336,6 @@ private:
|
||||
} // namespace sse
|
||||
|
||||
|
||||
|
||||
} // namespace httplib
|
||||
|
||||
#endif // CPPHTTPLIB_HTTPLIB_H
|
||||
|
||||
Reference in New Issue
Block a user