patch-2.2.13 linux/net/sunrpc/svcsock.c
Next file: linux/net/sunrpc/xprt.c
Previous file: linux/net/sunrpc/svc.c
Back to the patch index
Back to the overall index
- Lines: 48
- Date:
Tue Oct 19 17:14:02 1999
- Orig file:
v2.2.12/linux/net/sunrpc/svcsock.c
- Orig date:
Tue May 4 10:29:07 1999
diff -u --recursive --new-file v2.2.12/linux/net/sunrpc/svcsock.c linux/net/sunrpc/svcsock.c
@@ -531,16 +531,18 @@
ops = newsock->ops;
if ((err = ops->accept(sock, newsock, O_NONBLOCK)) < 0) {
- printk(KERN_WARNING "%s: accept failed (err %d)!\n",
- serv->sv_name, -err);
+ if (net_ratelimit())
+ printk(KERN_WARNING "%s: accept failed (err %d)!\n",
+ serv->sv_name, -err);
goto failed; /* aborted connection or whatever */
}
slen = sizeof(sin);
err = ops->getname(newsock, (struct sockaddr *) &sin, &slen, 1);
if (err < 0) {
- printk(KERN_WARNING "%s: peername failed (err %d)!\n",
- serv->sv_name, -err);
+ if (net_ratelimit())
+ printk(KERN_WARNING "%s: peername failed (err %d)!\n",
+ serv->sv_name, -err);
goto failed; /* aborted connection or whatever */
}
@@ -548,10 +550,11 @@
* hosts here, but we have no generic client tables. For now,
* we just punt connects from unprivileged ports. */
if (ntohs(sin.sin_port) >= 1024) {
- printk(KERN_WARNING
- "%s: connect from unprivileged port: %s:%d",
- serv->sv_name,
- in_ntoa(sin.sin_addr.s_addr), ntohs(sin.sin_port));
+ if (net_ratelimit())
+ printk(KERN_WARNING
+ "%s: connect from unprivileged port: %s:%d",
+ serv->sv_name,
+ in_ntoa(sin.sin_addr.s_addr), ntohs(sin.sin_port));
goto failed;
}
@@ -918,7 +921,7 @@
int error;
int type;
- dprintk("svc: svc_create_socket(%s, %d, %08lx:%d)\n",
+ dprintk("svc: svc_create_socket(%s, %d, %08x:%d)\n",
serv->sv_program->pg_name, protocol,
ntohl(sin->sin_addr.s_addr),
ntohs(sin->sin_port));
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)