diff options
| author | 2014-07-20 18:05:21 +0000 | |
|---|---|---|
| committer | 2014-07-20 18:05:21 +0000 | |
| commit | 7b90f98f7ed0e1bf3f4e3f790c91179eb4627560 (patch) | |
| tree | af188cbad8a06448924b5138d2bc64dbb3a8528a /sys/kern/subr_hibernate.c | |
| parent | Fix tcpdump(8) display of logical link control data in IEEE802 frames. (diff) | |
| download | wireguard-openbsd-7b90f98f7ed0e1bf3f4e3f790c91179eb4627560.tar.xz wireguard-openbsd-7b90f98f7ed0e1bf3f4e3f790c91179eb4627560.zip | |
Support hibernating to softraid crypto volumes.
much help and ok from deraadt@
Diffstat (limited to 'sys/kern/subr_hibernate.c')
| -rw-r--r-- | sys/kern/subr_hibernate.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/kern/subr_hibernate.c b/sys/kern/subr_hibernate.c index 6f54d7e3470..c8491bd4ee4 100644 --- a/sys/kern/subr_hibernate.c +++ b/sys/kern/subr_hibernate.c @@ -1,4 +1,4 @@ -/* $OpenBSD: subr_hibernate.c,v 1.97 2014/07/16 07:42:51 mlarkin Exp $ */ +/* $OpenBSD: subr_hibernate.c,v 1.98 2014/07/20 18:05:21 mlarkin Exp $ */ /* * Copyright (c) 2011 Ariane van der Steldt <ariane@stack.nl> @@ -686,7 +686,7 @@ get_hibernate_info(union hibernate_info *hib, int suspend) #endif /* ! NO_PROPOLICE */ /* Determine I/O function to use */ - hib->io_func = get_hibernate_io_function(); + hib->io_func = get_hibernate_io_function(swdevt[0].sw_dev); if (hib->io_func == NULL) return (1); @@ -694,7 +694,7 @@ get_hibernate_info(union hibernate_info *hib, int suspend) hib->dev = swdevt[0].sw_dev; /* Read disklabel (used to calculate signature and image offsets) */ - dl_ret = disk_readlabel(&dl, hib->dev, err_string, 128); + dl_ret = disk_readlabel(&dl, hib->dev, err_string, sizeof(err_string)); if (dl_ret) { printf("Hibernate error reading disklabel: %s\n", dl_ret); |
