diff options
author | Martin Natano <natano@cvs.openbsd.org> | 2016-04-16 22:23:02 +0000 |
---|---|---|
committer | Martin Natano <natano@cvs.openbsd.org> | 2016-04-16 22:23:02 +0000 |
commit | 1125bf8bf397d7c916481c0202d46868802a3c9c (patch) | |
tree | 49c26c161a0b0ceec357906997eea9993fca7bf9 | |
parent | 7b9cdc8b98ee55e5d4a072a29a24b3f3ba4af08e (diff) |
Replace bcopy() from struct bpf_timeval to struct timeval; those
structures are not exchangeable. This should unbreak connection timeouts
in rbootd, although I can't verify due to lack of rboot-able hardware.
ok guenther millert
-rw-r--r-- | usr.sbin/rbootd/bpf.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/rbootd/bpf.c b/usr.sbin/rbootd/bpf.c index b5baf0429dd..a7a068c5c6c 100644 --- a/usr.sbin/rbootd/bpf.c +++ b/usr.sbin/rbootd/bpf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bpf.c,v 1.23 2015/08/20 22:39:29 deraadt Exp $ */ +/* $OpenBSD: bpf.c,v 1.24 2016/04/16 22:23:01 natano Exp $ */ /* $NetBSD: bpf.c,v 1.5.2.1 1995/11/14 08:45:42 thorpej Exp $ */ /* @@ -362,8 +362,8 @@ BpfRead(RMPCONN *rconn, int doread) caplen); else { rconn->rmplen = caplen; - bcopy((char *)&bhp->bh_tstamp, (char *)&rconn->tstamp, - sizeof(struct timeval)); + rconn->tstamp.tv_sec = bhp->bh_tstamp.tv_sec; + rconn->tstamp.tv_usec = bhp->bh_tstamp.tv_usec; bcopy((char *)bp + hdrlen, (char *)&rconn->rmp, caplen); } bp += BPF_WORDALIGN(caplen + hdrlen); |