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

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