From 732eff53f0510108732b26cffdac60a99905b4c5 Mon Sep 17 00:00:00 2001 From: Leandro Pereira Date: Sun, 3 May 2020 10:46:10 -0700 Subject: hi_module_get_about() should return a const pointer --- modules/devices.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) (limited to 'modules/devices.c') diff --git a/modules/devices.c b/modules/devices.c index a90cbc0a..fef8b559 100644 --- a/modules/devices.c +++ b/modules/devices.c @@ -867,17 +867,16 @@ void hi_module_deinit(void) g_module_close(cups); } -ModuleAbout *hi_module_get_about(void) -{ - static ModuleAbout ma[] = { - { - .author = "Leandro A. F. Pereira", - .description = N_("Gathers information about hardware devices"), - .version = VERSION, - .license = "GNU GPL version 2"} +const ModuleAbout *hi_module_get_about(void) +{ + const static ModuleAbout ma = { + .author = "Leandro A. F. Pereira", + .description = N_("Gathers information about hardware devices"), + .version = VERSION, + .license = "GNU GPL version 2", }; - return ma; + return &ma; } gchar **hi_module_get_dependencies(void) -- cgit v1.2.3