summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorhsu <hsu@FreeBSD.org>2003-08-05 00:27:54 +0000
committerhsu <hsu@FreeBSD.org>2003-08-05 00:27:54 +0000
commitfb82c18f66d416fe2da9e9472fea685cd3fb8d87 (patch)
tree07ac04d1488e8869ef4928f625d48c49dc2e6458 /sys
parent7bf5fa9caf39cc731d7d0a4284ae21ba234fdd96 (diff)
downloadFreeBSD-src-fb82c18f66d416fe2da9e9472fea685cd3fb8d87.zip
FreeBSD-src-fb82c18f66d416fe2da9e9472fea685cd3fb8d87.tar.gz
Make the second argument to sooptcopyout() constant in order to
simplify the upcoming PIM patches. Submitted by: Pavlin Radoslavov <pavlin@icir.org>
Diffstat (limited to 'sys')
-rw-r--r--sys/kern/uipc_socket.c5
-rw-r--r--sys/sys/socketvar.h2
2 files changed, 2 insertions, 5 deletions
diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c
index 0c85717..41e461f 100644
--- a/sys/kern/uipc_socket.c
+++ b/sys/kern/uipc_socket.c
@@ -1425,10 +1425,7 @@ bad:
/* Helper routine for getsockopt */
int
-sooptcopyout(sopt, buf, len)
- struct sockopt *sopt;
- void *buf;
- size_t len;
+sooptcopyout(struct sockopt *sopt, const void *buf, size_t len)
{
int error;
size_t valsize;
diff --git a/sys/sys/socketvar.h b/sys/sys/socketvar.h
index 223ccc2..1bc4c33 100644
--- a/sys/sys/socketvar.h
+++ b/sys/sys/socketvar.h
@@ -401,7 +401,7 @@ int solisten(struct socket *so, int backlog, struct thread *td);
struct socket *
sonewconn(struct socket *head, int connstatus);
int sooptcopyin(struct sockopt *sopt, void *buf, size_t len, size_t minlen);
-int sooptcopyout(struct sockopt *sopt, void *buf, size_t len);
+int sooptcopyout(struct sockopt *sopt, const void *buf, size_t len);
/* XXX; prepare mbuf for (__FreeBSD__ < 3) routines. */
int soopt_getm(struct sockopt *sopt, struct mbuf **mp);
OpenPOWER on IntegriCloud