From 64675b64ebd200161bc3abf77cb4a23842730f82 Mon Sep 17 00:00:00 2001 From: Robert Fewell <14uBobIT@gmail.com> Date: Sun, 23 Jul 2017 12:41:15 +0100 Subject: [PATCH] These files have the QofLogModule defined but never used In two minds on this, comment the line out or add macro to stop it showing up as defined but never used, chose the latter. --- src/app-utils/guile-util.c | 5 +++-- src/business/business-gnome/dialog-invoice.c | 4 +++- src/import-export/csv-imp/gnc-csv-account-map.c | 4 +++- src/plugins/bi_import/dialog-bi-import-gui.c | 5 ++++- src/register/register-gnome/table-gnome.c | 4 +++- 5 files changed, 16 insertions(+), 6 deletions(-) diff --git a/src/app-utils/guile-util.c b/src/app-utils/guile-util.c index 043f5c7161..1f17ef373a 100644 --- a/src/app-utils/guile-util.c +++ b/src/app-utils/guile-util.c @@ -57,9 +57,10 @@ #include "guile-util.h" #include "guile-mappings.h" -/* This static indicates the debugging module this .o belongs to. */ -static QofLogModule log_module = GNC_MOD_GUILE; +#define UNUSED_VAR __attribute__ ((unused)) +/* This static indicates the debugging module this .o belongs to. */ +static QofLogModule UNUSED_VAR log_module = GNC_MOD_GUILE; struct _setters { diff --git a/src/business/business-gnome/dialog-invoice.c b/src/business/business-gnome/dialog-invoice.c index 8af5b38211..6f591185cf 100644 --- a/src/business/business-gnome/dialog-invoice.c +++ b/src/business/business-gnome/dialog-invoice.c @@ -126,7 +126,9 @@ struct _invoice_select_window GncOwner owner_def; }; -static QofLogModule log_module = G_LOG_DOMAIN; //G_LOG_BUSINESS; +#define UNUSED_VAR __attribute__ ((unused)) + +static QofLogModule UNUSED_VAR log_module = G_LOG_DOMAIN; //G_LOG_BUSINESS; /** This data structure does double duty. It is used to maintain * information for the "New Invoice" dialog, and it is also used to diff --git a/src/import-export/csv-imp/gnc-csv-account-map.c b/src/import-export/csv-imp/gnc-csv-account-map.c index 29d7c6b0cc..88bd260fd2 100644 --- a/src/import-export/csv-imp/gnc-csv-account-map.c +++ b/src/import-export/csv-imp/gnc-csv-account-map.c @@ -39,8 +39,10 @@ #define IMPORT_FULL_PATH "FullPath" #define IMPORT_ACCOUNT "Account" +#define UNUSED_VAR __attribute__ ((unused)) + /* This static indicates the debugging module that this .o belongs to. */ -static QofLogModule log_module = G_LOG_DOMAIN; +static QofLogModule UNUSED_VAR log_module = G_LOG_DOMAIN; /************************************************** * account_imap_destroy diff --git a/src/plugins/bi_import/dialog-bi-import-gui.c b/src/plugins/bi_import/dialog-bi-import-gui.c index e3ac07579b..ca073da47f 100644 --- a/src/plugins/bi_import/dialog-bi-import-gui.c +++ b/src/plugins/bi_import/dialog-bi-import-gui.c @@ -75,7 +75,10 @@ void gnc_import_gui_type_cb (GtkWidget *widget, gpointer data); // utils static gchar *gnc_input_dialog (GtkWidget *parent, const gchar *title, const gchar *msg, const gchar *default_input); static void gnc_info2_dialog (GtkWidget *parent, const gchar *title, const gchar *msg); -static QofLogModule log_module = G_LOG_DOMAIN; //G_LOG_BUSINESS; + +#define UNUSED_VAR __attribute__ ((unused)) + +static QofLogModule UNUSED_VAR log_module = G_LOG_DOMAIN; //G_LOG_BUSINESS; BillImportGui * gnc_plugin_bi_import_showGUI(void) diff --git a/src/register/register-gnome/table-gnome.c b/src/register/register-gnome/table-gnome.c index 3dbf7a930d..8f9650e9cf 100644 --- a/src/register/register-gnome/table-gnome.c +++ b/src/register/register-gnome/table-gnome.c @@ -59,8 +59,10 @@ /** Static Globals *****************************************************/ +#define UNUSED_VAR __attribute__ ((unused)) + /* This static indicates the debugging module that this .o belongs to. */ -static QofLogModule log_module = GNC_MOD_REGISTER; +static QofLogModule UNUSED_VAR log_module = GNC_MOD_REGISTER; /** Implementation *****************************************************/