Blame SOURCES/0001-Remove-unused-not_supported-function.patch

bda309
From 8853f5a49587f00a7d2a5c8c7e52480a16bbdb02 Mon Sep 17 00:00:00 2001
bda309
From: "Richard W.M. Jones" <rjones@redhat.com>
bda309
Date: Fri, 5 Feb 2016 16:28:34 +0000
bda309
Subject: [PATCH] Remove unused 'not_supported' function.
bda309
bda309
Found by compiling under GCC 6.  The warning was:
bda309
bda309
In file included from libvirt_c.c:2058:0:
bda309
libvirt_c_epilogue.c:89:1: error: 'not_supported' defined but not used [-Werror=unused-function]
bda309
 not_supported (const char *fn)
bda309
 ^~~~~~~~~~~~~
bda309
---
bda309
 libvirt/libvirt_c_epilogue.c | 15 ---------------
bda309
 libvirt/libvirt_c_prologue.c |  1 -
bda309
 2 files changed, 16 deletions(-)
bda309
bda309
diff --git a/libvirt/libvirt_c_epilogue.c b/libvirt/libvirt_c_epilogue.c
bda309
index 4972e50..fa592c9 100644
bda309
--- a/libvirt/libvirt_c_epilogue.c
bda309
+++ b/libvirt/libvirt_c_epilogue.c
bda309
@@ -84,21 +84,6 @@ _raise_virterror (const char *fn)
bda309
   (void) caml__frame;
bda309
 }
bda309
 
bda309
-/* Raise an error if a function is not supported. */
bda309
-static void
bda309
-not_supported (const char *fn)
bda309
-{
bda309
-  CAMLparam0 ();
bda309
-  CAMLlocal1 (fnv);
bda309
-
bda309
-  fnv = caml_copy_string (fn);
bda309
-  caml_raise_with_arg (*caml_named_value ("ocaml_libvirt_not_supported"), fnv);
bda309
-
bda309
-  /*NOTREACHED*/
bda309
-  /* Suppresses a compiler warning. */
bda309
-  (void) caml__frame;
bda309
-}
bda309
-
bda309
 /* Convert the virErrorNumber, virErrorDomain and virErrorLevel enums
bda309
  * into values (longs because they are variants in OCaml).
bda309
  *
bda309
diff --git a/libvirt/libvirt_c_prologue.c b/libvirt/libvirt_c_prologue.c
bda309
index bf972e9..710c0d6 100644
bda309
--- a/libvirt/libvirt_c_prologue.c
bda309
+++ b/libvirt/libvirt_c_prologue.c
bda309
@@ -25,7 +25,6 @@ typedef value (*Val_ptr_t) (void *);
bda309
 static value Val_opt (void *ptr, Val_ptr_t Val_ptr);
bda309
 /*static value option_default (value option, value deflt);*/
bda309
 static void _raise_virterror (const char *fn) Noreturn;
bda309
-static void not_supported (const char *fn) Noreturn;
bda309
 static value Val_virterror (virErrorPtr err);
bda309
 
bda309
 /* Use this around synchronous libvirt API calls to release the OCaml
bda309
-- 
bda309
2.5.0
bda309