dcavalca / rpms / grub2

Forked from rpms/grub2 3 years ago
Clone

Blame SOURCES/0017-freebsd-hostdisk.c-is-only-ever-compiled-on-FreeBSD.patch

28f7f8
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
39700a
From: Colin Watson <cjwatson@ubuntu.com>
39700a
Date: Fri, 17 Jan 2014 02:30:52 +0000
28f7f8
Subject: [PATCH] freebsd/hostdisk.c is only ever compiled on FreeBSD
39700a
39700a
* grub-core/osdep/freebsd/hostdisk.c (grub_util_fd_open): Remove
39700a
redundant preprocessor conditional.
39700a
---
39700a
 grub-core/osdep/freebsd/hostdisk.c | 2 --
28f7f8
 ChangeLog                          | 5 +++++
39700a
 2 files changed, 5 insertions(+), 2 deletions(-)
39700a
39700a
diff --git a/grub-core/osdep/freebsd/hostdisk.c b/grub-core/osdep/freebsd/hostdisk.c
28f7f8
index bd5fddb9150..eb202dcc831 100644
39700a
--- a/grub-core/osdep/freebsd/hostdisk.c
39700a
+++ b/grub-core/osdep/freebsd/hostdisk.c
39700a
@@ -108,7 +108,6 @@ grub_util_fd_open (const char *os_dev, int flags)
39700a
 
39700a
   ret = open (os_dev, flags, S_IROTH | S_IRGRP | S_IRUSR | S_IWUSR);
39700a
 
39700a
-#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
39700a
   if (! (sysctl_oldflags & 0x10)
39700a
       && sysctlbyname ("kern.geom.debugflags", NULL , 0, &sysctl_oldflags, sysctl_size))
39700a
     {
39700a
@@ -116,7 +115,6 @@ grub_util_fd_open (const char *os_dev, int flags)
39700a
       close (ret);
39700a
       return GRUB_UTIL_FD_INVALID;
39700a
     }
39700a
-#endif
39700a
 
39700a
   return ret;
39700a
 }
28f7f8
diff --git a/ChangeLog b/ChangeLog
28f7f8
index b445f121586..6613b4ee52b 100644
28f7f8
--- a/ChangeLog
28f7f8
+++ b/ChangeLog
28f7f8
@@ -1,3 +1,8 @@
28f7f8
+2014-01-17  Colin Watson  <cjwatson@debian.org>
28f7f8
+
28f7f8
+	* grub-core/osdep/freebsd/hostdisk.c (grub_util_fd_open): Remove
28f7f8
+	redundant preprocessor conditional.
28f7f8
+
28f7f8
 2014-01-08  Colin Watson  <cjwatson@ubuntu.com>
28f7f8
 
28f7f8
 	* Makefile.util.def (grub-macbless): Change mansection to 8.