commit | e4e458b45c5861808674eebfea94cee2258bb2ea | [log] [tgz] |
---|---|---|
author | Arjun Sreedharan <[email protected]> | Sat Dec 06 17:10:43 2014 +0530 |
committer | Arnaldo Carvalho de Melo <[email protected]> | Tue Dec 09 10:06:29 2014 -0300 |
tree | 8864aff017c25af0c6c4a5294e0a73a6aec2bd12 | |
parent | 2e77784bb7d882647c33d8e75a650625e6df0f8b [diff] [blame] |
calloc/xcalloc: Fix argument order The calloc() and xcalloc() functions takes @nmemb first and then @size. Fix all w/ pattern "calloc\s*(\s*sizeof". Signed-off-by: Arjun Sreedharan <[email protected]> Cc: "Yann E. MORIN" <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Paul Mackerras <[email protected]> Cc: Peter Zijlstra <[email protected]> Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
diff --git a/scripts/kconfig/mconf.c b/scripts/kconfig/mconf.c index 14cea74..4dd3755 100644 --- a/scripts/kconfig/mconf.c +++ b/scripts/kconfig/mconf.c
@@ -330,10 +330,10 @@ list_for_each_entry(sp, &trail, entries) { if (sp->text) { if (pos) { - pos->next = xcalloc(sizeof(*pos), 1); + pos->next = xcalloc(1, sizeof(*pos)); pos = pos->next; } else { - subtitles = pos = xcalloc(sizeof(*pos), 1); + subtitles = pos = xcalloc(1, sizeof(*pos)); } pos->text = sp->text; }