Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/distrib/utils/sysinst Use PRIi64 for printing tmp_ramdisk_si...
details: https://anonhg.NetBSD.org/src/rev/171ef295979f
branches: trunk
changeset: 768586:171ef295979f
user: phx <phx%NetBSD.org@localhost>
date: Sun Aug 21 15:06:41 2011 +0000
description:
Use PRIi64 for printing tmp_ramdisk_size, which is a daddr_t (64 bits).
This fixes the size of the ramdisk file system being 0 on big endian
systems.
diffstat:
distrib/utils/sysinst/disks.c | 15 +++++++++------
1 files changed, 9 insertions(+), 6 deletions(-)
diffs (33 lines):
diff -r 07c14536a5e6 -r 171ef295979f distrib/utils/sysinst/disks.c
--- a/distrib/utils/sysinst/disks.c Sun Aug 21 15:06:27 2011 +0000
+++ b/distrib/utils/sysinst/disks.c Sun Aug 21 15:06:41 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: disks.c,v 1.115 2011/08/16 18:28:41 wiz Exp $ */
+/* $NetBSD: disks.c,v 1.116 2011/08/21 15:06:41 phx Exp $ */
/*
* Copyright 1997 Piermont Information Systems Inc.
@@ -747,15 +747,18 @@
if (tmp_ramdisk_size != 0) {
#ifdef HAVE_TMPFS
- scripting_fprintf(f, "tmpfs\t\t/tmp\ttmpfs\trw,-m=1777,-s=%d\n",
+ scripting_fprintf(f, "tmpfs\t\t/tmp\ttmpfs\trw,-m=1777,-s=%"
+ PRIi64 "\n",
tmp_ramdisk_size * 512);
#else
if (swap_dev != -1)
- scripting_fprintf(f, "/dev/%s%c\t\t/tmp\tmfs\trw,-s=%d\n",
- diskdev, 'a' + swap_dev, tmp_ramdisk_size);
+ scripting_fprintf(f, "/dev/%s%c\t\t/tmp\tmfs\trw,-s=%"
+ PRIi64 "\n",
+ diskdev, 'a' + swap_dev, tmp_ramdisk_size);
else
- scripting_fprintf(f, "swap\t\t/tmp\tmfs\trw,-s=%d\n",
- tmp_ramdisk_size);
+ scripting_fprintf(f, "swap\t\t/tmp\tmfs\trw,-s=%"
+ PRIi64 "\n",
+ tmp_ramdisk_size);
#endif
}
Home |
Main Index |
Thread Index |
Old Index