From: Andy Shevchenko Date: Mon, 21 Dec 2020 12:30:07 +0000 (+0200) Subject: IOMUX: Drop indentation level by removing redundant 'else' X-Git-Url: http://git.dujemihanovic.xyz/img/static/git-favicon.png?a=commitdiff_plain;h=420782c45b992c55201ee43426dcae2ffd9807a4;p=u-boot.git IOMUX: Drop indentation level by removing redundant 'else' Obviously the following has unnecessary indentation level in 'else' branch. if (foo) { ... return; } else { ... } Drop indentation level by removing redundant 'else'. Signed-off-by: Andy Shevchenko Reviewed-by: Simon Glass --- diff --git a/common/iomux.c b/common/iomux.c index 7991235d11..126d92ce85 100644 --- a/common/iomux.c +++ b/common/iomux.c @@ -126,12 +126,12 @@ int iomux_doenv(const int console, const char *arg) if (cs_idx == 0) { free(cons_set); return 1; - } else { - /* Works even if console_devices[console] is NULL. */ - free(console_devices[console]); - console_devices[console] = cons_set; - cd_count[console] = cs_idx; } + + /* Works even if console_devices[console] is NULL. */ + free(console_devices[console]); + console_devices[console] = cons_set; + cd_count[console] = cs_idx; return 0; } #endif /* CONSOLE_MUX */