Skip to content

Commit 1bcbf8f

Browse files
author
guanqiao
committed
Disable daemon, and increase command buffer size
Signed-off-by: guanqiao <guanqiao@staff.sina.com.cn>
1 parent 7396286 commit 1bcbf8f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/server.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ static int debug; /* enable this to printf */
3030
#define PROC_BUFF 8192
3131
unsigned char proc_buff[PROC_BUFF];
3232

33-
#define CMD_BUFF 16384
33+
#define CMD_BUFF 163840
3434
unsigned char cmd_buff[CMD_BUFF];
3535

3636
struct jrpc_server my_server;
@@ -309,10 +309,12 @@ int main(int argc, char **argv)
309309
* so, don't close them; but we want to mute errors
310310
* just like a typical daemon
311311
*/
312+
#if 0
312313
daemon(0, 1);
313314
fd = open ("/dev/null", O_RDWR, 0);
314315
if (fd != -1)
315316
dup2 (fd, STDERR_FILENO);
317+
#endif
316318

317319
jrpc_server_init(&my_server, PORT);
318320
jrpc_register_procedure(&my_server, say_hello, "SayHello", NULL);

0 commit comments

Comments
 (0)