Blame SOURCES/0001-Fix-build-with-GCC-8.patch

4ff70e
From b8fdfcae060bdffb15d81e68cdff011105013eb0 Mon Sep 17 00:00:00 2001
4ff70e
From: Michael Catanzaro <mcatanzaro@igalia.com>
4ff70e
Date: Fri, 18 May 2018 09:56:16 -0500
4ff70e
Subject: [PATCH] Fix build with GCC 8
4ff70e
4ff70e
Yelp enables -Werror by default, so it's responsible for predicting and
4ff70e
fixing future compiler warnings that only an oracle could know about. In
4ff70e
this case, that turned out to be -Werror=cast-function-type.
4ff70e
---
4ff70e
 libyelp/yelp-docbook-document.c | 6 +++---
4ff70e
 libyelp/yelp-document.c         | 4 ++--
4ff70e
 libyelp/yelp-help-list.c        | 2 +-
4ff70e
 libyelp/yelp-info-document.c    | 2 +-
4ff70e
 libyelp/yelp-mallard-document.c | 6 +++---
4ff70e
 libyelp/yelp-man-document.c     | 2 +-
4ff70e
 libyelp/yelp-simple-document.c  | 2 +-
4ff70e
 libyelp/yelp-transform.c        | 2 +-
4ff70e
 libyelp/yelp-uri.c              | 2 +-
4ff70e
 9 files changed, 14 insertions(+), 14 deletions(-)
4ff70e
4ff70e
diff --git a/libyelp/yelp-docbook-document.c b/libyelp/yelp-docbook-document.c
4ff70e
index 9b430b09..6ecaf316 100644
4ff70e
--- a/libyelp/yelp-docbook-document.c
4ff70e
+++ b/libyelp/yelp-docbook-document.c
4ff70e
@@ -273,7 +273,7 @@ docbook_request_page (YelpDocument         *document,
4ff70e
         priv->process_running = TRUE;
4ff70e
         g_object_ref (document);
4ff70e
         priv->thread = g_thread_new ("docbook-page",
4ff70e
-                                     (GThreadFunc) docbook_process,
4ff70e
+                                     (GThreadFunc)(GCallback) docbook_process,
4ff70e
                                      document);
4ff70e
         break;
4ff70e
     case DOCBOOK_STATE_PARSING:
4ff70e
@@ -495,7 +495,7 @@ docbook_reload (YelpDocbookDocument *docbook)
4ff70e
     priv->process_running = TRUE;
4ff70e
     g_object_ref (docbook);
4ff70e
     priv->thread = g_thread_new ("docbook-reload",
4ff70e
-                                 (GThreadFunc) docbook_process,
4ff70e
+                                 (GThreadFunc)(GCallback) docbook_process,
4ff70e
                                  docbook);
4ff70e
 
4ff70e
     g_mutex_unlock (&priv->mutex);
4ff70e
@@ -1077,7 +1077,7 @@ docbook_index (YelpDocument *document)
4ff70e
     priv = GET_PRIV (document);
4ff70e
     g_object_ref (document);
4ff70e
     priv->index = g_thread_new ("docbook-index",
4ff70e
-                                (GThreadFunc) docbook_index_threaded,
4ff70e
+                                (GThreadFunc)(GCallback) docbook_index_threaded,
4ff70e
                                 document);
4ff70e
     priv->index_running = TRUE;
4ff70e
 }
4ff70e
diff --git a/libyelp/yelp-document.c b/libyelp/yelp-document.c
4ff70e
index 6adbbb1d..c1eec9cc 100644
4ff70e
--- a/libyelp/yelp-document.c
4ff70e
+++ b/libyelp/yelp-document.c
4ff70e
@@ -330,7 +330,7 @@ yelp_document_dispose (GObject *object)
4ff70e
 
4ff70e
     if (document->priv->reqs_all) {
4ff70e
 	g_slist_foreach (document->priv->reqs_all,
4ff70e
-			 (GFunc) request_try_free,
4ff70e
+			 (GFunc)(GCallback) request_try_free,
4ff70e
 			 NULL);
4ff70e
 	g_slist_free (document->priv->reqs_all);
4ff70e
 	document->priv->reqs_all = NULL;
4ff70e
@@ -338,7 +338,7 @@ yelp_document_dispose (GObject *object)
4ff70e
 
4ff70e
     if (document->priv->reqs_search) {
4ff70e
 	g_slist_foreach (document->priv->reqs_search,
4ff70e
-			 (GFunc) request_try_free,
4ff70e
+			 (GFunc)(GCallback) request_try_free,
4ff70e
 			 NULL);
4ff70e
 	g_slist_free (document->priv->reqs_search);
4ff70e
 	document->priv->reqs_search = NULL;
4ff70e
diff --git a/libyelp/yelp-help-list.c b/libyelp/yelp-help-list.c
4ff70e
index 9005e48f..cbac98bf 100644
4ff70e
--- a/libyelp/yelp-help-list.c
4ff70e
+++ b/libyelp/yelp-help-list.c
4ff70e
@@ -210,7 +210,7 @@ help_list_request_page (YelpDocument          *document,
4ff70e
         priv->process_running = TRUE;
4ff70e
         g_object_ref (document);
4ff70e
         priv->thread = g_thread_new ("helplist-page",
4ff70e
-                                     (GThreadFunc) help_list_think,
4ff70e
+                                     (GThreadFunc)(GCallback) help_list_think,
4ff70e
                                      document);
4ff70e
     }
4ff70e
     priv->pending = g_slist_prepend (priv->pending, g_strdup (page_id));
4ff70e
diff --git a/libyelp/yelp-info-document.c b/libyelp/yelp-info-document.c
4ff70e
index 7b532744..d55be325 100644
4ff70e
--- a/libyelp/yelp-info-document.c
4ff70e
+++ b/libyelp/yelp-info-document.c
4ff70e
@@ -209,7 +209,7 @@ info_request_page (YelpDocument         *document,
4ff70e
 	priv->process_running = TRUE;
4ff70e
         g_object_ref (document);
4ff70e
 	priv->thread = g_thread_new ("info-page",
4ff70e
-                                     (GThreadFunc) info_document_process,
4ff70e
+                                     (GThreadFunc)(GCallback) info_document_process,
4ff70e
                                      document);
4ff70e
 	break;
4ff70e
     case INFO_STATE_PARSING:
4ff70e
diff --git a/libyelp/yelp-mallard-document.c b/libyelp/yelp-mallard-document.c
4ff70e
index fc7c4d7c..74fc80ee 100644
4ff70e
--- a/libyelp/yelp-mallard-document.c
4ff70e
+++ b/libyelp/yelp-mallard-document.c
4ff70e
@@ -287,7 +287,7 @@ mallard_request_page (YelpDocument         *document,
4ff70e
         priv->thread_running = TRUE;
4ff70e
         g_object_ref (document);
4ff70e
         priv->thread = g_thread_new ("mallard-page",
4ff70e
-                                     (GThreadFunc) mallard_think,
4ff70e
+                                     (GThreadFunc)(GCallback) mallard_think,
4ff70e
                                      document);
4ff70e
     }
4ff70e
 
4ff70e
@@ -1100,7 +1100,7 @@ mallard_index (YelpDocument *document)
4ff70e
     priv = GET_PRIV (document);
4ff70e
     g_object_ref (document);
4ff70e
     priv->index = g_thread_new ("mallard-index",
4ff70e
-                                (GThreadFunc) mallard_index_threaded,
4ff70e
+                                (GThreadFunc)(GCallback) mallard_index_threaded,
4ff70e
                                 document);
4ff70e
     priv->index_running = TRUE;
4ff70e
 }
4ff70e
@@ -1148,7 +1148,7 @@ mallard_monitor_changed (GFileMonitor         *monitor,
4ff70e
     priv->thread_running = TRUE;
4ff70e
     g_object_ref (mallard);
4ff70e
     priv->thread = g_thread_new ("mallard-reload",
4ff70e
-                                 (GThreadFunc) mallard_think,
4ff70e
+                                 (GThreadFunc)(GCallback) mallard_think,
4ff70e
                                  mallard);
4ff70e
 
4ff70e
     g_mutex_unlock (&priv->mutex);
4ff70e
diff --git a/libyelp/yelp-man-document.c b/libyelp/yelp-man-document.c
4ff70e
index 4e165d57..ad7fab4f 100644
4ff70e
--- a/libyelp/yelp-man-document.c
4ff70e
+++ b/libyelp/yelp-man-document.c
4ff70e
@@ -243,7 +243,7 @@ man_request_page (YelpDocument         *document,
4ff70e
         yelp_document_set_page_id (document, priv->page_id, priv->page_id);
4ff70e
         yelp_document_set_root_id (document, priv->page_id, priv->page_id);
4ff70e
 	priv->thread = g_thread_new ("man-page",
4ff70e
-                                     (GThreadFunc) man_document_process,
4ff70e
+                                     (GThreadFunc)(GCallback) man_document_process,
4ff70e
                                      document);
4ff70e
 	break;
4ff70e
     case MAN_STATE_PARSING:
4ff70e
diff --git a/libyelp/yelp-simple-document.c b/libyelp/yelp-simple-document.c
4ff70e
index 501d7881..595efa83 100644
4ff70e
--- a/libyelp/yelp-simple-document.c
4ff70e
+++ b/libyelp/yelp-simple-document.c
4ff70e
@@ -131,7 +131,7 @@ yelp_simple_document_dispose (GObject *object)
4ff70e
     YelpSimpleDocument *document = YELP_SIMPLE_DOCUMENT (object);
4ff70e
 
4ff70e
     if (document->priv->reqs) {
4ff70e
-	g_slist_foreach (document->priv->reqs, (GFunc) request_try_free, NULL);
4ff70e
+	g_slist_foreach (document->priv->reqs, (GFunc)(GCallback) request_try_free, NULL);
4ff70e
 	g_slist_free (document->priv->reqs);
4ff70e
 	document->priv->reqs = NULL;
4ff70e
     }
4ff70e
diff --git a/libyelp/yelp-transform.c b/libyelp/yelp-transform.c
4ff70e
index 334438af..7a5dc86e 100644
4ff70e
--- a/libyelp/yelp-transform.c
4ff70e
+++ b/libyelp/yelp-transform.c
4ff70e
@@ -298,7 +298,7 @@ yelp_transform_start (YelpTransform       *transform,
4ff70e
     priv->running = TRUE;
4ff70e
     g_object_ref (transform);
4ff70e
     priv->thread = g_thread_new ("transform-run",
4ff70e
-                                 (GThreadFunc) transform_run,
4ff70e
+                                 (GThreadFunc)(GCallback) transform_run,
4ff70e
                                  transform);
4ff70e
     g_mutex_unlock (&priv->mutex);
4ff70e
 
4ff70e
diff --git a/libyelp/yelp-uri.c b/libyelp/yelp-uri.c
4ff70e
index 317beead..f20b167e 100644
4ff70e
--- a/libyelp/yelp-uri.c
4ff70e
+++ b/libyelp/yelp-uri.c
4ff70e
@@ -298,7 +298,7 @@ resolve_start (YelpUri *uri)
4ff70e
     if (priv->resolver == NULL) {
4ff70e
         g_object_ref (uri);
4ff70e
         priv->resolver = g_thread_new ("uri-resolve",
4ff70e
-                                       (GThreadFunc) resolve_async,
4ff70e
+                                       (GThreadFunc)(GCallback) resolve_async,
4ff70e
                                        uri);
4ff70e
     }
4ff70e
 }
4ff70e
-- 
4ff70e
2.17.1
4ff70e