From 6971b00e1b2eb9ff6834c1e689c26fb07cb52084 Mon Sep 17 00:00:00 2001 From: rockerBOO Date: Tue, 23 Sep 2025 02:31:49 -0400 Subject: [PATCH] Use NULL --- src/config/parse_config.h | 2 +- src/ext-protocol/tablet.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/config/parse_config.h b/src/config/parse_config.h index 6f03ab0f..d82dfc30 100644 --- a/src/config/parse_config.h +++ b/src/config/parse_config.h @@ -2573,7 +2573,7 @@ void set_value_default() { config.unfocused_opacity = unfocused_opacity; /* Tablet */ - config.tablet_output_name = strdup(""); + config.tablet_output_name = NULL; memcpy(config.shadowscolor, shadowscolor, sizeof(shadowscolor)); diff --git a/src/ext-protocol/tablet.h b/src/ext-protocol/tablet.h index 3e15c107..39cf011a 100644 --- a/src/ext-protocol/tablet.h +++ b/src/ext-protocol/tablet.h @@ -50,7 +50,7 @@ void createtablet(struct wlr_input_device *device) { send_events_mode); wlr_cursor_attach_input_device(cursor, device); // Map tablet to specific monitor if configured - if (config.tablet_output_name[0] != '\0') { + if (config.tablet_output_name) { Monitor *target_monitor = find_monitor_by_name(config.tablet_output_name); if (target_monitor) { wlr_log(WLR_INFO, "Mapping input to output for device: %s", config.tablet_output_name);