From cbf1a58f6c28a9811eedc9f1d99fce07f901bc86 Mon Sep 17 00:00:00 2001 From: Yoshihiro Takahashi Date: Sun, 1 May 2005 04:14:01 +0000 Subject: [PATCH] Merged from src/sbin/fdisk/fdisk.c revision 1.77. --- sbin/fdisk_pc98/fdisk.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sbin/fdisk_pc98/fdisk.c b/sbin/fdisk_pc98/fdisk.c index 1a87f4f9543e..b90a4732762c 100644 --- a/sbin/fdisk_pc98/fdisk.c +++ b/sbin/fdisk_pc98/fdisk.c @@ -833,7 +833,7 @@ open_disk(int flag) return -3; for (i = 0; i < NDOSPART; i++) { snprintf(buf, sizeof(buf), "%ss%d", disk, i + 1); - fdw = open(buf, O_RDONLY); + fdw = open(buf, rwmode); if (fdw == -1) continue; break; @@ -852,7 +852,7 @@ open_disk(int flag) return -3; for (p = 1; p < 5; p++) { asprintf(&s, "%ss%d", disk, p); - fdw = open(s, O_RDONLY); + fdw = open(s, rwmode); free(s); if (fdw == -1) continue;