diff options
author | Matthew Dempsky <matthew@cvs.openbsd.org> | 2012-05-29 06:32:58 +0000 |
---|---|---|
committer | Matthew Dempsky <matthew@cvs.openbsd.org> | 2012-05-29 06:32:58 +0000 |
commit | aa17b02b3660f5e16a4220b1cce172ff148e3cc5 (patch) | |
tree | 50a1ccde1e2b159cb20f4466b949bb4602d85c91 /sys/arch/sgi | |
parent | b3c0080c852e5135cfec02dae6ab1936116ebad1 (diff) |
When writing the new volume header to disk, write back the whole
sector rather than just the bytes for the volume header itself.
Silences the "sloppy I/O" warnings triggered by sgi's distrib scripts.
tested and ok deraadt
Diffstat (limited to 'sys/arch/sgi')
-rw-r--r-- | sys/arch/sgi/stand/sgivol/sgivol.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/arch/sgi/stand/sgivol/sgivol.c b/sys/arch/sgi/stand/sgivol/sgivol.c index 1871983bb06..38d558f3da7 100644 --- a/sys/arch/sgi/stand/sgivol/sgivol.c +++ b/sys/arch/sgi/stand/sgivol/sgivol.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sgivol.c,v 1.17 2010/05/18 04:41:14 dlg Exp $ */ +/* $OpenBSD: sgivol.c,v 1.18 2012/05/29 06:32:57 matthew Exp $ */ /* $NetBSD: sgivol.c,v 1.8 2003/11/08 04:59:00 sekiya Exp $ */ /*- @@ -521,7 +521,7 @@ write_volhdr(void) display_vol(); if (lseek(fd, 0, SEEK_SET) == -1) err(1, "lseek 0"); - if (write(fd, buf, sizeof(struct sgilabel)) != sizeof(struct sgilabel)) + if (write(fd, buf, bufsize) != bufsize) err(1, "write volhdr"); } |