projects
/
carl9170fw.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
kconfig: squash prop_alloc() into menu_add_prop()
[carl9170fw.git]
/
config
/
menu.c
diff --git
a/config/menu.c
b/config/menu.c
index 5a43784ded2cf80bc4ed3b12bc54c071e0c13a08..8b772ced755dd382cef4b184499627c582aaab21 100644
(file)
--- a/
config/menu.c
+++ b/
config/menu.c
@@
-127,12
+127,28
@@
void menu_set_type(int type)
static struct property *menu_add_prop(enum prop_type type, struct expr *expr,
struct expr *dep)
{
static struct property *menu_add_prop(enum prop_type type, struct expr *expr,
struct expr *dep)
{
- struct property *prop
= prop_alloc(type, current_entry->sym)
;
+ struct property *prop;
+ prop = xmalloc(sizeof(*prop));
+ memset(prop, 0, sizeof(*prop));
+ prop->type = type;
+ prop->file = current_file;
+ prop->lineno = zconf_lineno();
prop->menu = current_entry;
prop->expr = expr;
prop->visible.expr = dep;
prop->menu = current_entry;
prop->expr = expr;
prop->visible.expr = dep;
+ /* append property to the prop list of symbol */
+ if (current_entry->sym) {
+ struct property **propp;
+
+ for (propp = ¤t_entry->sym->prop;
+ *propp;
+ propp = &(*propp)->next)
+ ;
+ *propp = prop;
+ }
+
return prop;
}
return prop;
}