mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-02-07 06:53:33 +00:00
Make some quick fixes
This commit is contained in:
parent
d3efa47f81
commit
a5b483f2d4
2 changed files with 2 additions and 5 deletions
|
@ -195,9 +195,6 @@ privileged static void klog(const char *b, size_t n) {
|
|||
: "=a"(rax), "=D"(rdi), "=S"(rsi), "=d"(rdx)
|
||||
: "0"(__NR_write), "1"(2), "2"(b), "3"(n)
|
||||
: "rcx", "r8", "r9", "r10", "r11", "memory", "cc");
|
||||
if (rax < 0) {
|
||||
notpossible;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -87,7 +87,7 @@
|
|||
*/
|
||||
|
||||
#define PORT 8080 // default server listening port
|
||||
#define WORKERS 9001 // size of http client thread pool
|
||||
#define WORKERS 1001 // size of http client thread pool
|
||||
#define SUPERVISE_MS 1000 // how often to stat() asset files
|
||||
#define KEEPALIVE_MS 60000 // max time to keep idle conn open
|
||||
#define MELTALIVE_MS 2000 // panic keepalive under heavy load
|
||||
|
@ -642,7 +642,7 @@ void *HttpWorker(void *arg) {
|
|||
struct sockaddr_in addr = {.sin_family = AF_INET, .sin_port = htons(g_port)};
|
||||
|
||||
BlockSignals();
|
||||
DontRunOnFirstCpus(2);
|
||||
DontRunOnFirstCpus(1);
|
||||
CHECK_NE(-1, (server = socket(AF_INET, SOCK_STREAM, 0)));
|
||||
pthread_setname_np(pthread_self(), _gc(xasprintf("HTTP #%d", id)));
|
||||
setsockopt(server, SOL_SOCKET, SO_RCVTIMEO, &timeo, sizeof(timeo));
|
||||
|
|
Loading…
Reference in a new issue