From: krw Date: Tue, 27 Jul 2010 00:07:26 +0000 (+0000) Subject: Nuke 'sectoffset'. A stub variable no longer used except to supply X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=a622d9864f00933da39c6ef46750b82fab86e0fb;p=openbsd Nuke 'sectoffset'. A stub variable no longer used except to supply the value 0 to one function call. Use 0 there, eliminate the variable and the pointless verbose verbiage that always displayed the same value. ok deraadt@ matthew@ --- diff --git a/sbin/disklabel/disklabel.c b/sbin/disklabel/disklabel.c index 8106f1d4a8e..6b1e24df180 100644 --- a/sbin/disklabel/disklabel.c +++ b/sbin/disklabel/disklabel.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disklabel.c,v 1.166 2010/06/30 23:44:06 halex Exp $ */ +/* $OpenBSD: disklabel.c,v 1.167 2010/07/27 00:07:26 krw Exp $ */ /* * Copyright (c) 1987, 1993 @@ -363,7 +363,6 @@ writelabel(int f, char *boot, struct disklabel *lp) { #if NUMBOOT > 0 int writeable; - off_t sectoffset = 0; #endif #if NUMBOOT > 0 @@ -390,12 +389,8 @@ writelabel(int f, char *boot, struct disklabel *lp) return (1); } } - if (verbose) - printf("writing label to block %lld (0x%qx)\n", - (long long)sectoffset/DEV_BSIZE, - (long long)sectoffset/DEV_BSIZE); if (!donothing) { - if (lseek(f, sectoffset, SEEK_SET) < 0) { + if (lseek(f, 0, SEEK_SET) < 0) { perror("lseek"); return (1); }