+/**
+ * @file
+ *
+ * Controlling the libsigrokdecode message logging functionality.
+ */
+
+/**
+ * @defgroup grp_logging Logging
+ *
+ * Controlling the libsigrokdecode message logging functionality.
+ *
+ * @{
+ */
+
+/* Currently selected libsigrokdecode loglevel. Default: SRD_LOG_WARN. */
+static int cur_loglevel = SRD_LOG_WARN; /* Show errors+warnings per default. */
+
+/* Function prototype. */
+static int srd_logv(void *cb_data, int loglevel, const char *format,
+ va_list args);
+
+/* Pointer to the currently selected log callback. Default: srd_logv(). */
+static srd_log_callback srd_log_cb = srd_logv;
+
+/*
+ * Pointer to private data that can be passed to the log callback.
+ * This can be used (for example) by C++ GUIs to pass a "this" pointer.
+ */
+static void *srd_log_cb_data = NULL;