mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-19 16:26:22 +00:00
slightly improve command_defs[]
* make the struct `const` * use designated initializers * remove `CMD_NOxyz` macros * fix function-pointer correctness of `sub_func[]` Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
This commit is contained in:
@@ -68,7 +68,11 @@ typedef struct cmd_t
|
||||
int min_args;
|
||||
int max_args;
|
||||
void (*setting_func)(void);
|
||||
void* sub_funcs[50][2];
|
||||
struct
|
||||
{
|
||||
const char* cmd;
|
||||
gboolean (*func)(ProfWin* window, const char* const command, gchar** args);
|
||||
} sub_funcs[50];
|
||||
gboolean (*func)(ProfWin* window, const char* const command, gchar** args);
|
||||
CommandHelp help;
|
||||
} Command;
|
||||
|
||||
Reference in New Issue
Block a user