summaryrefslogtreecommitdiff
path: root/sys/dev/pci
diff options
context:
space:
mode:
authorJason Wright <jason@cvs.openbsd.org>2001-04-29 00:37:12 +0000
committerJason Wright <jason@cvs.openbsd.org>2001-04-29 00:37:12 +0000
commit91384628bb4f830b0638a0665c881bb4367da5e6 (patch)
tree81d1fdb2b38db92bc8367067940a781703b8b6c6 /sys/dev/pci
parent1cef621f9ad54e43627227a0318fb95f7a92b52f (diff)
When expanding the session table, only copy the number of sessions already
there to the new table; from stephen@etunnels.com (PR 1801).
Diffstat (limited to 'sys/dev/pci')
-rw-r--r--sys/dev/pci/ubsec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/pci/ubsec.c b/sys/dev/pci/ubsec.c
index a93de2d5a65..5def3676e08 100644
--- a/sys/dev/pci/ubsec.c
+++ b/sys/dev/pci/ubsec.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ubsec.c,v 1.43 2001/04/06 16:27:45 jason Exp $ */
+/* $OpenBSD: ubsec.c,v 1.44 2001/04/29 00:37:11 jason Exp $ */
/*
* Copyright (c) 2000 Jason L. Wright (jason@thought.net)
@@ -445,7 +445,7 @@ ubsec_newsession(sidp, cri)
sizeof(struct ubsec_session), M_DEVBUF, M_NOWAIT);
if (ses == NULL)
return (ENOMEM);
- bcopy(sc->sc_sessions, ses, (sesn + 1) *
+ bcopy(sc->sc_sessions, ses, sesn *
sizeof(struct ubsec_session));
bzero(sc->sc_sessions, sesn *
sizeof(struct ubsec_session));