Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Zwinkau
libfirm
Commits
f1faabda
Commit
f1faabda
authored
Dec 06, 2012
by
Christoph Mallon
Browse files
libcore: Check, that a pointer to a char array is passed to LC_OPT_ENT_STR().
parent
6cdf99e5
Changes
2
Hide whitespace changes
Inline
Side-by-side
ir/be/bemain.c
View file @
f1faabda
...
...
@@ -135,11 +135,11 @@ static const lc_opt_table_entry_t be_main_options[] = {
LC_OPT_ENT_BOOL
(
"profilegenerate"
,
"instrument the code for execution count profiling"
,
&
be_options
.
opt_profile_generate
),
LC_OPT_ENT_BOOL
(
"profileuse"
,
"use existing profile data"
,
&
be_options
.
opt_profile_use
),
LC_OPT_ENT_BOOL
(
"statev"
,
"dump statistic events"
,
&
be_options
.
statev
),
LC_OPT_ENT_STR
(
"filtev"
,
"filter for stat events (regex if support is active"
,
be_options
.
filtev
),
LC_OPT_ENT_STR
(
"filtev"
,
"filter for stat events (regex if support is active"
,
&
be_options
.
filtev
),
LC_OPT_ENT_BOOL
(
"verboseasm"
,
"enable verbose assembler output"
,
&
be_options
.
verbose_asm
),
LC_OPT_ENT_STR
(
"ilp.server"
,
"the ilp server name"
,
be_options
.
ilp_server
),
LC_OPT_ENT_STR
(
"ilp.solver"
,
"the ilp solver name"
,
be_options
.
ilp_solver
),
LC_OPT_ENT_STR
(
"ilp.server"
,
"the ilp server name"
,
&
be_options
.
ilp_server
),
LC_OPT_ENT_STR
(
"ilp.solver"
,
"the ilp solver name"
,
&
be_options
.
ilp_solver
),
LC_OPT_LAST
};
...
...
ir/libcore/lc_opts.h
View file @
f1faabda
...
...
@@ -123,8 +123,9 @@ typedef struct {
#define LC_OPT_ENT_NEGBOOL(name, desc, addr) \
_LC_OPT_ENT(name, desc, lc_opt_type_negboolean, int, addr, 0, lc_opt_std_cb, lc_opt_std_dump, lc_opt_bool_dump_vals)
typedef
char
lc_opt_str_t
[];
#define LC_OPT_ENT_STR(name, desc, buf) \
_LC_OPT_ENT(name, desc, lc_opt_type_string,
char
, buf, sizeof(buf), lc_opt_std_cb, lc_opt_std_dump, NULL)
_LC_OPT_ENT(name, desc, lc_opt_type_string,
lc_opt_str_t
, buf, sizeof(
*
buf), lc_opt_std_cb, lc_opt_std_dump, NULL)
#define LC_OPT_LAST \
_LC_OPT_ENT(NULL, NULL, lc_opt_type_invalid, void, NULL, 0, NULL, NULL, NULL)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment