You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
459 B

  1. --- a/src/server.c
  2. +++ b/src/server.c
  3. @@ -10,6 +10,7 @@
  4. #include <stdlib.h>
  5. #include <string.h>
  6. #include <sys/stat.h>
  7. +#include <syslog.h>
  8. #include "utils.h"
  9. @@ -478,7 +479,8 @@ int main(int argc, char **argv) {
  10. return -1;
  11. }
  12. - lws_set_log_level(debug_level, NULL);
  13. + openlog("ttyd", LOG_NDELAY | LOG_PID, LOG_DAEMON);
  14. + lws_set_log_level(debug_level, lwsl_emit_syslog);
  15. #if LWS_LIBRARY_VERSION_MAJOR >= 2
  16. char server_hdr[128] = "";