Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/distrib/i386/floppies/bootfloppy-common - fix PAD=yes code s...



details:   https://anonhg.NetBSD.org/src/rev/3b3f5c250579
branches:  trunk
changeset: 521684:3b3f5c250579
user:      lukem <lukem%NetBSD.org@localhost>
date:      Sun Feb 03 14:56:00 2002 +0000

description:
- fix PAD=yes code so that it won't potentially trash some of the last
  8k of the kernel.
- minor cleanup of an error message

diffstat:

 distrib/i386/floppies/bootfloppy-common/Makefile.inc |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (29 lines):

diff -r f4f4c3ffe2ba -r 3b3f5c250579 distrib/i386/floppies/bootfloppy-common/Makefile.inc
--- a/distrib/i386/floppies/bootfloppy-common/Makefile.inc      Sun Feb 03 14:10:02 2002 +0000
+++ b/distrib/i386/floppies/bootfloppy-common/Makefile.inc      Sun Feb 03 14:56:00 2002 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile.inc,v 1.33 2001/11/08 02:10:26 christos Exp $
+#      $NetBSD: Makefile.inc,v 1.34 2002/02/03 14:56:00 lukem Exp $
 
 # TOP is assumed to be defined by Makefile including this one.
 
@@ -38,7 +38,7 @@
                disks=$$(($$size / $$dksize + 1)); \
                if test $$size -gt $$dksize; then \
                        bytes=$$(($$size - $$dksize));    \
-                       echo "Image is $$bytes ($$(($$bytes / 1024))K) too big \
+                       echo "Image is $$bytes ($$(($$bytes / 1024))K) too big\
                                to fit on one disk."; \
                        exit 1; \
                else \
@@ -48,8 +48,8 @@
                echo; \
                 bytes=$$(($$dksize * $$disks - $$size));    \
                if test "${PAD}" = "yes"; then \
-                       bytes=$$(($$bytes + 8 * 1024)); \
-                       echo "Padding image with $$bytes bytes"; \
+                       size=$$(($$size + 8 * 1024)); \
+                       echo "Padding image with $$bytes bytes from $$size"; \
                        sectors=$$(($$bytes / 512)); \
                        ssize=$$(($$size / 512)); \
                        dd if=/dev/zero bs=512 seek=$${ssize} of=${IMAGE}.tmp \



Home | Main Index | Thread Index | Old Index