--- source/commands2.c.orig 2012-03-19 13:10:06.802575691 +0100 +++ source/commands2.c 2012-03-19 13:10:26.401100927 +0100 @@ -2575,7 +2575,7 @@ unsigned short port = 0; { char buf[BIG_BUFFER_SIZE+1]; sprintf(buf, socket_path, port); - if ((u = open(buf, O_CREAT|O_WRONLY)) != -1) + if ((u = open(buf, O_CREAT|O_WRONLY, 0644)) != -1) { chmod(buf, SOCKMODE); chown(buf, getuid(), getgid()); --- source/dcc.c.orig 2012-03-19 13:18:43.390562273 +0100 +++ source/dcc.c 2012-03-19 13:17:23.729859849 +0100 @@ -2273,7 +2273,7 @@ char *nick; tmp = m_strdup(new->filename); if (!(fullname = expand_twiddle(tmp))) malloc_strcpy(&fullname, tmp); - if ((new->file = open(fullname, O_WRONLY | O_CREAT | O_BINARY)) != -1) + if ((new->file = open(fullname, O_WRONLY | O_CREAT | O_BINARY, 0644)) != -1) { if ((new = dcc_create(nick, new->filename, passwd, 0, port? atol(port) : 0, DCC_REFILEREAD, (tdcc?DCC_TDCC:0) | DCC_TWOCLIENTS|DCC_OFFER, start_dcc_get))) new->blocksize = blocksize;