Source-Changes-HG archive

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

[src/trunk]: src/lib/librumpuser More finegrained disklabel macro checks, for...



details:   https://anonhg.NetBSD.org/src/rev/92cbdf61f33d
branches:  trunk
changeset: 333450:92cbdf61f33d
user:      pooka <pooka%NetBSD.org@localhost>
date:      Tue Nov 04 21:08:12 2014 +0000

description:
More finegrained disklabel macro checks, for FreeBSD

diffstat:

 lib/librumpuser/rumpuser_file.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (36 lines):

diff -r 76ce705459ec -r 92cbdf61f33d lib/librumpuser/rumpuser_file.c
--- a/lib/librumpuser/rumpuser_file.c   Tue Nov 04 19:56:44 2014 +0000
+++ b/lib/librumpuser/rumpuser_file.c   Tue Nov 04 21:08:12 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rumpuser_file.c,v 1.3 2014/11/04 19:05:17 pooka Exp $  */
+/*     $NetBSD: rumpuser_file.c,v 1.4 2014/11/04 21:08:12 pooka Exp $  */
 
 /*
  * Copyright (c) 2007-2010 Antti Kantee.  All Rights Reserved.
@@ -30,7 +30,7 @@
 #include "rumpuser_port.h"
 
 #if !defined(lint)
-__RCSID("$NetBSD: rumpuser_file.c,v 1.3 2014/11/04 19:05:17 pooka Exp $");
+__RCSID("$NetBSD: rumpuser_file.c,v 1.4 2014/11/04 21:08:12 pooka Exp $");
 #endif /* !lint */
 
 #include <sys/ioctl.h>
@@ -126,7 +126,7 @@
                        goto out;
                }
 
-#if !defined(DIOCGDINFO) && !defined(DIOCGWEDGEINFO)
+#if (!defined(DIOCGDINFO) || !defined(DISKPART)) && !defined(DIOCGWEDGEINFO)
                {
                off_t off = lseek(fd, 0, SEEK_END);
                if (off != 0) {
@@ -140,7 +140,7 @@
                }
 #else
 
-#if defined(DIOCGDINFO)
+#if defined(DIOCGDINFO) && defined(DISKPART)
                {
                struct disklabel lab;
                struct partition *parta;



Home | Main Index | Thread Index | Old Index