about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--calmwm.c6
-rw-r--r--calmwm.h2
-rw-r--r--client.c6
-rw-r--r--screen.c6
4 files changed, 2 insertions, 18 deletions
diff --git a/calmwm.c b/calmwm.c
index b9d29d0..4ece6e2 100644
--- a/calmwm.c
+++ b/calmwm.c
@@ -29,10 +29,10 @@ Cursor				 Cursor_select;
 Cursor				 Cursor_default;
 Cursor				 Cursor_question;
 
-struct screen_ctx_q		 Screenq;
+struct screen_ctx_q		 Screenq = TAILQ_HEAD_INITIALIZER(Screenq);
 struct screen_ctx		*Curscreen;
 
-struct client_ctx_q		 Clientq;
+struct client_ctx_q		 Clientq = TAILQ_HEAD_INITIALIZER(Clientq);
 
 int				 HasXinerama, HasRandr, Randr_ev;
 int				 Starting;
@@ -73,9 +73,7 @@ main(int argc, char **argv)
 	Starting = 1;
 	dpy_init(display_name);
 
-	screen_init();
 	group_init();
-	client_init();
 
 	bzero(&Conf, sizeof(Conf));
 	conf_setup(&Conf, conf_file);
diff --git a/calmwm.h b/calmwm.h
index eb4c0f2..a60dee1 100644
--- a/calmwm.h
+++ b/calmwm.h
@@ -327,7 +327,6 @@ int			 input_keycodetrans(KeyCode, u_int, enum ctltype *,
 __dead void		 usage(void);
 
 struct client_ctx	*client_find(Window);
-void			 client_init(void);
 struct client_ctx	*client_new(Window, struct screen_ctx *, int);
 int			 client_delete(struct client_ctx *);
 void			 client_setactive(struct client_ctx *, int);
@@ -388,7 +387,6 @@ void			*xmalloc(size_t);
 void			*xcalloc(size_t, size_t);
 char			*xstrdup(const char *);
 
-void			 screen_init(void);
 struct screen_ctx	*screen_fromroot(Window);
 struct screen_ctx	*screen_current(void);
 void			 screen_updatestackingorder(void);
diff --git a/client.c b/client.c
index 4ae84fd..b6e6ad2 100644
--- a/client.c
+++ b/client.c
@@ -32,12 +32,6 @@ static int			 client_inbound(struct client_ctx *, int, int);
 static char		 emptystring[] = "";
 struct client_ctx	*_curcc = NULL;
 
-void
-client_init(void)
-{
-	TAILQ_INIT(&Clientq);
-}
-
 struct client_ctx *
 client_find(Window win)
 {
diff --git a/screen.c b/screen.c
index e538cd8..6c7be33 100644
--- a/screen.c
+++ b/screen.c
@@ -23,12 +23,6 @@
 
 extern struct screen_ctx	*Curscreen;
 
-void
-screen_init(void)
-{
-	TAILQ_INIT(&Screenq);
-}
-
 struct screen_ctx *
 screen_fromroot(Window rootwin)
 {