From f8cb6e0f391a724ae2eb4b00c744935a37d6fdcb Mon Sep 17 00:00:00 2001 From: Benjamin Tissoires Date: Sun, 6 Sep 2015 16:12:50 -0400 Subject: [PATCH] etekcity-drv: fix compiler warning we should not access resolution before it gets initialized... Signed-off-by: Benjamin Tissoires --- src/driver-etekcity.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/driver-etekcity.c b/src/driver-etekcity.c index fe6ebda9..01a1984a 100644 --- a/src/driver-etekcity.c +++ b/src/driver-etekcity.c @@ -503,9 +503,9 @@ etekcity_read_profile(struct ratbag_profile *profile, unsigned int index) hz = report_rate; if (!(setting_report->dpi_mask & (1 << i))) { /* the profile is disabled, overwrite it */ - resolution->dpi_x = 0; - resolution->dpi_y = 0; - resolution->hz = 0; + dpi_x = 0; + dpi_y = 0; + hz = 0; } resolution = ratbag_resolution_init(profile, i, dpi_x, dpi_y, hz); ratbag_resolution_set_cap(resolution,