This commit is contained in:
cinap_lenrek 2014-10-29 17:31:37 +01:00
commit 482e03c64d
10 changed files with 15 additions and 15 deletions

View file

@ -143,7 +143,7 @@ putfile(SConn *conn, char *id, char *pf)
snprint(s, Maxmsg, "%s/store/%s/%s", SECSTORE_DIR, id, pf); snprint(s, Maxmsg, "%s/store/%s/%s", SECSTORE_DIR, id, pf);
pd = create(s, OWRITE, 0660); pd = create(s, OWRITE, 0660);
if(pd < 0){ if(pd < 0){
syslog(0, LOG, "can't open %s: %r\n", s); syslog(0, LOG, "can't open %s: %r", s);
return -1; return -1;
} }
while(len > 0){ while(len > 0){

View file

@ -397,7 +397,7 @@ secureidcheck(char *user, char *response)
shared.len = strlen(radiussecret); shared.len = strlen(radiussecret);
ip = getipv4addr(); ip = getipv4addr();
if(ip == nil){ if(ip == nil){
syslog(0, AUTHLOG, "no interfaces: %r\n"); syslog(0, AUTHLOG, "no interfaces: %r");
goto out; goto out;
} }
if(setAttribute(req, R_NASIPAddress, ip + IPv4off, 4) < 0) if(setAttribute(req, R_NASIPAddress, ip + IPv4off, 4) < 0)
@ -413,7 +413,7 @@ secureidcheck(char *user, char *response)
t = ndbsearch(netdb, &s, "sys", "lra-radius"); t = ndbsearch(netdb, &s, "sys", "lra-radius");
if(t == nil){ if(t == nil){
syslog(0, AUTHLOG, "secureidcheck: nil radius sys search: %r\n"); syslog(0, AUTHLOG, "secureidcheck: nil radius sys search: %r");
goto out; goto out;
} }
for(nt = t; nt; nt = nt->entry){ for(nt = t; nt; nt = nt->entry){

View file

@ -634,7 +634,7 @@ rwrite(Mfile *mf)
b->inode.length = c.thdr.offset + s.rhdr.count; b->inode.length = c.thdr.offset + s.rhdr.count;
mf->qid.vers++; mf->qid.vers++;
if (s.rhdr.count != c.thdr.count) if (s.rhdr.count != c.thdr.count)
syslog(0, "cfslog", "rhdr.count %ud, thdr.count %ud\n", syslog(0, "cfslog", "rhdr.count %ud, thdr.count %ud",
s.rhdr.count, c.thdr.count); s.rhdr.count, c.thdr.count);
if(fwrite(&ic, b, buf, c.thdr.offset, s.rhdr.count) == s.rhdr.count){ if(fwrite(&ic, b, buf, c.thdr.offset, s.rhdr.count) == s.rhdr.count){
iinc(&ic, b); iinc(&ic, b);

View file

@ -261,7 +261,7 @@ lognolease(Binding *b)
/* complain if we haven't in the last 5 minutes */ /* complain if we haven't in the last 5 minutes */
if(now - b->lastcomplained < 5*60) if(now - b->lastcomplained < 5*60)
return; return;
syslog(0, blog, "dhcp: lease for %I to %s ended at %ld but still in use\n", syslog(0, blog, "dhcp: lease for %I to %s ended at %ld but still in use",
b->ip, b->boundto != nil ? b->boundto : "?", b->lease); b->ip, b->boundto != nil ? b->boundto : "?", b->lease);
b->lastcomplained = now; b->lastcomplained = now;
} }

View file

@ -487,7 +487,7 @@ uncomp(PPP *ppp, Block *b, int *protop, Block **r)
*protop = 0; *protop = 0;
s = ppp->uncstate; s = ppp->uncstate;
if(BLEN(b) < 2){ if(BLEN(b) < 2){
syslog(0, "ppp", ": mppc: short packet\n"); syslog(0, "ppp", ": mppc: short packet");
freeb(b); freeb(b);
return nil; return nil;
} }
@ -506,7 +506,7 @@ uncomp(PPP *ppp, Block *b, int *protop, Block **r)
} }
if(BLEN(b) < 2){ if(BLEN(b) < 2){
syslog(0, "ppp", ": mppc: short packet\n"); syslog(0, "ppp", ": mppc: short packet");
freeb(b); freeb(b);
*protop = 0; *protop = 0;
return nil; return nil;

View file

@ -1346,11 +1346,11 @@ rcv(PPP *ppp, Pstate *p, Block *b)
break; break;
case Lcoderej: case Lcoderej:
//newstate(ppp, p, Sclosed); //newstate(ppp, p, Sclosed);
syslog(0, LOG, "code reject %d\n", m->data[0]); syslog(0, LOG, "code reject %d", m->data[0]);
break; break;
case Lprotorej: case Lprotorej:
proto = nhgets(m->data); proto = nhgets(m->data);
netlog("ppp: proto reject %ux\n", proto); netlog("ppp: proto reject %ux", proto);
if(proto == Pccp) if(proto == Pccp)
newstate(ppp, ppp->ccp, Sclosed); newstate(ppp, ppp->ccp, Sclosed);
break; break;
@ -2218,7 +2218,7 @@ getchap(PPP *ppp, Block *b)
netlog("ppp: chap failed\n"); netlog("ppp: chap failed\n");
break; break;
default: default:
syslog(0, LOG, "chap code %d?\n", m->code); syslog(0, LOG, "chap code %d?", m->code);
break; break;
} }
qunlock(ppp); qunlock(ppp);

View file

@ -253,7 +253,7 @@ uncomp(PPP *ppp, Block *bb, int *protop, Block **reply)
uncs = ppp->uncstate; uncs = ppp->uncstate;
if(BLEN(bb) < 4){ if(BLEN(bb) < 4){
syslog(0, "ppp", ": thwack: short packet\n"); syslog(0, "ppp", ": thwack: short packet");
freeb(bb); freeb(bb);
return nil; return nil;
} }
@ -279,7 +279,7 @@ uncomp(PPP *ppp, Block *bb, int *protop, Block **reply)
n = unthwack(&uncs->ut, b->wptr, ThwMaxBlock, bb->rptr, BLEN(bb), seq & ThwSeqMask); n = unthwack(&uncs->ut, b->wptr, ThwMaxBlock, bb->rptr, BLEN(bb), seq & ThwSeqMask);
freeb(bb); freeb(bb);
if(n < 2){ if(n < 2){
syslog(0, "ppp", ": unthwack: short or corrupted packet %d seq=%ld\n", n, seq); syslog(0, "ppp", ": unthwack: short or corrupted packet %d seq=%ld", n, seq);
netlog("unthwack: short or corrupted packet n=%d seq=%ld: %s\n", n, seq, uncs->ut.err); netlog("unthwack: short or corrupted packet n=%d seq=%ld: %s\n", n, seq, uncs->ut.err);
freeb(b); freeb(b);

View file

@ -1452,7 +1452,7 @@ receiver(Dev *d)
argv[argc++] = dev->t->name; argv[argc++] = dev->t->name;
argv[argc] = 0; argv[argc] = 0;
exec(prog, argv); exec(prog, argv);
syslog(0, LOGFILE, "can't exec %s: %r\n", prog); syslog(0, LOGFILE, "can't exec %s: %r", prog);
exits(0); exits(0);
default: default:
/* wait till child gets the device open */ /* wait till child gets the device open */

View file

@ -131,7 +131,7 @@ main(int argc, char**argv)
while((n = read(0, buf, sizeof(buf)-1)) > 0){ while((n = read(0, buf, sizeof(buf)-1)) > 0){
if(i++ == 0 && strncmp(buf, "From", 4) != 0){ if(i++ == 0 && strncmp(buf, "From", 4) != 0){
buf[n] = 0; buf[n] = 0;
syslog(0, "smtp", "qer usys data starts with %-40.40s\n", buf); syslog(0, "smtp", "qer usys data starts with %-40.40s", buf);
} }
if(write(fd, buf, n) != n) if(write(fd, buf, n) != n)
error("writing data file %s", s_to_c(f)); error("writing data file %s", s_to_c(f));

View file

@ -517,7 +517,7 @@ dofile(Dir *dp)
if(wm->msg[0]){ if(wm->msg[0]){
if(debug) if(debug)
fprint(2, "[%d] wm->msg == %s\n", getpid(), wm->msg); fprint(2, "[%d] wm->msg == %s\n", getpid(), wm->msg);
syslog(0, runqlog, "message: %s\n", wm->msg); syslog(0, runqlog, "message: %s", wm->msg);
if(strstr(wm->msg, "Ignore") != nil){ if(strstr(wm->msg, "Ignore") != nil){
/* fix for fish/chips, leave message alone */ /* fix for fish/chips, leave message alone */
logit("ignoring", dp->name, av); logit("ignoring", dp->name, av);