]> www.infradead.org Git - users/sagi/nvme-cli.git/commit
util: Cleanup argconfig parse function
authorTokunori Ikegami <ikegami.t@gmail.com>
Fri, 24 Mar 2023 17:37:59 +0000 (02:37 +0900)
committerDaniel Wagner <wagi@monom.org>
Mon, 27 Mar 2023 09:28:38 +0000 (11:28 +0200)
commitd9d3a8190ee4a65f214e8cdf7a2fd4033676c0d4
tree9e9b55ddaaf5b7e349365a1ec7fc2462054b5520
parent53fabc37f86c3549e7eb16db8d61f42de875bc13
util: Cleanup argconfig parse function

1. Split to parse config type function
2. Change if else statement to switch case statement
3. Use calloc instead of malloc
4. Delete unused while 0 statement
5. Add argconfig error common function

Signed-off-by: Tokunori Ikegami <ikegami.t@gmail.com>
util/argconfig.c