summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/interface.c1
-rw-r--r--src/pa-sink-ctl.c2
-rw-r--r--src/sink.c5
-rw-r--r--src/sink.h6
4 files changed, 8 insertions, 6 deletions
diff --git a/src/interface.c b/src/interface.c
index c545bf9..3c02e78 100644
--- a/src/interface.c
+++ b/src/interface.c
@@ -14,7 +14,6 @@
#define VOLUME_BAR_LEN 50
#define H_MSG_BOX 3
-extern GArray *sink_list;
extern pa_context* context;
static WINDOW *menu_win;
diff --git a/src/pa-sink-ctl.c b/src/pa-sink-ctl.c
index 3d9421d..767a5a6 100644
--- a/src/pa-sink-ctl.c
+++ b/src/pa-sink-ctl.c
@@ -7,8 +7,6 @@
#include "interface.h"
#include "pa-sink-ctl.h"
-GArray *sink_list = NULL;
-
pa_context *context = NULL;
static gboolean info_callbacks_finished = TRUE;
diff --git a/src/sink.c b/src/sink.c
index 8da3048..9f36f3e 100644
--- a/src/sink.c
+++ b/src/sink.c
@@ -1,9 +1,8 @@
#include <glib.h>
-#include "sink_input.h"
+#define SINK_C
#include "sink.h"
-
-extern GArray *sink_list;
+#include "sink_input.h"
/*
* init a sink list
diff --git a/src/sink.h b/src/sink.h
index 4e46045..cccbe1b 100644
--- a/src/sink.h
+++ b/src/sink.h
@@ -1,6 +1,12 @@
#ifndef SINK_H
#define SINK_H
+#ifdef SINK_C
+GArray *sink_list;
+#else
+extern GArray *sink_list;
+#endif
+
#include <glib.h>
#include <pulse/pulseaudio.h>