From d2ad352c7f187268cf6902117cdae80fd1108ef1 Mon Sep 17 00:00:00 2001 From: William McKinnon Date: Sat, 20 May 2023 17:03:20 -0400 Subject: [PATCH] fix: maybe-uninitialized error --- sway/ipc-json.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sway/ipc-json.c b/sway/ipc-json.c index 717ebf78..c7e94a81 100644 --- a/sway/ipc-json.c +++ b/sway/ipc-json.c @@ -343,7 +343,7 @@ static void ipc_json_describe_enabled_output(struct sway_output *output, json_object_object_add(layer, "namespace", json_object_new_string(lsurface->layer_surface->namespace)); - char *layer_name; + char *layer_name = NULL; switch (lsurface->layer) { case ZWLR_LAYER_SHELL_V1_LAYER_BACKGROUND: layer_name = "background";