]> git.ipfire.org Git - thirdparty/mdadm.git/commit - mdadm.h
Change char* to enum in context->update & refactor code
authorMateusz Kusiak <mateusz.kusiak@intel.com>
Mon, 2 Jan 2023 08:35:24 +0000 (09:35 +0100)
committerJes Sorensen <jes@trained-monkey.org>
Wed, 4 Jan 2023 15:20:58 +0000 (10:20 -0500)
commit3a87fa67112dc2c2c3664aeecd0b49cb4b6ceaa9
tree7e9017d8c79ccaef5a740ea8c0eaf36cd5288f8d
parentf2e8393bd7223c419aaa33c45feeb5c75440b986
Change char* to enum in context->update & refactor code

Storing update option in string is bad for frequent comparisons and
error prone.
Replace char array with enum so already existing enum is passed around
instead of string.
Adapt code to changes.

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@intel.com>
Signed-off-by: Jes Sorensen <jes@trained-monkey.org>
Assemble.c
mdadm.c
mdadm.h