summaryrefslogtreecommitdiff
path: root/disk-utils/mkswap.c
diff options
context:
space:
mode:
Diffstat (limited to 'disk-utils/mkswap.c')
-rw-r--r--disk-utils/mkswap.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/disk-utils/mkswap.c b/disk-utils/mkswap.c
index f7dbdf39..9d1ca3d5 100644
--- a/disk-utils/mkswap.c
+++ b/disk-utils/mkswap.c
@@ -132,10 +132,6 @@ is_sparc64(void) {
*
* What to do? Let us allow the user to specify the pagesize explicitly.
*
- * Update 05-Feb-2007 (kzak):
- * - use sysconf(_SC_PAGESIZE) to be consistent with the rest of
- * util-linux code. It is the standardized and preferred way of
- * querying page size.
*/
static int user_pagesize;
static int pagesize;
@@ -145,7 +141,7 @@ struct swap_header_v1 *p;
static void
init_signature_page(void) {
- int kernel_pagesize = pagesize = (int) sysconf(_SC_PAGESIZE);
+ int kernel_pagesize = pagesize = getpagesize();
if (user_pagesize) {
if ((user_pagesize & (user_pagesize-1)) ||