Skip to content

Commit d09181b

Browse files
EZForeverarthw
authored andcommitted
server : fix OpenSSL build (remove obsolete LOG_INFO) (ggml-org#9529)
1 parent 6e0564c commit d09181b

File tree

1 file changed

+2
-11
lines changed

1 file changed

+2
-11
lines changed

examples/server/server.cpp

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2254,14 +2254,6 @@ static void log_server_request(const httplib::Request & req, const httplib::Resp
22542254
return;
22552255
}
22562256

2257-
//LOG_INFO("request", {
2258-
// {"remote_addr", req.remote_addr},
2259-
// {"remote_port", req.remote_port},
2260-
// {"status", res.status},
2261-
// {"method", req.method},
2262-
// {"path", req.path},
2263-
// {"params", req.params},
2264-
//});
22652257
LOG_INF("request: %s %s %s %d\n", req.method.c_str(), req.path.c_str(), req.remote_addr.c_str(), res.status);
22662258

22672259
LOG_DBG("request: %s\n", req.body.c_str());
@@ -2318,12 +2310,12 @@ int main(int argc, char ** argv) {
23182310
std::unique_ptr<httplib::Server> svr;
23192311
#ifdef CPPHTTPLIB_OPENSSL_SUPPORT
23202312
if (params.ssl_file_key != "" && params.ssl_file_cert != "") {
2321-
LOG_INFO("Running with SSL", {{"key", params.ssl_file_key}, {"cert", params.ssl_file_cert}});
2313+
LOG_INF("Running with SSL: key = %s, cert = %s\n", params.ssl_file_key.c_str(), params.ssl_file_cert.c_str());
23222314
svr.reset(
23232315
new httplib::SSLServer(params.ssl_file_cert.c_str(), params.ssl_file_key.c_str())
23242316
);
23252317
} else {
2326-
LOG_INFO("Running without SSL", {});
2318+
LOG_INF("Running without SSL\n");
23272319
svr.reset(new httplib::Server());
23282320
}
23292321
#else
@@ -3108,7 +3100,6 @@ int main(int argc, char ** argv) {
31083100
std::thread t([&]() { svr->listen_after_bind(); });
31093101
svr->wait_until_ready();
31103102

3111-
//LOG_INFO("HTTP server is listening", log_data);
31123103
LOG_INF("%s: HTTP server is listening, hostname: %s, port: %d, http threads: %d\n", __func__, params.hostname.c_str(), params.port, params.n_threads_http);
31133104

31143105
// load the model

0 commit comments

Comments
 (0)