lib/conf: accept entries of form key=value
In INI config, split key based on whitespace AND symbol '=' This allows to have same format as FIO configs FIO style config will be used for bdevperf config file Change-Id: I92c501c839842919afb5c23ed935be010ae2b168 Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/3151 Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
This commit is contained in:
parent
ee7f961655
commit
367c980b45
@ -63,6 +63,7 @@ struct spdk_conf {
|
||||
};
|
||||
|
||||
#define CF_DELIM " \t"
|
||||
#define CF_DELIM_KEY " \t="
|
||||
|
||||
#define LIB_MAX_TMPBUF 1024
|
||||
|
||||
@ -501,7 +502,7 @@ parse_line(struct spdk_conf *cp, char *lp)
|
||||
SPDK_ERRLOG("unknown section\n");
|
||||
return -1;
|
||||
}
|
||||
key = spdk_strsepq(&arg, CF_DELIM);
|
||||
key = spdk_strsepq(&arg, CF_DELIM_KEY);
|
||||
if (key == NULL) {
|
||||
SPDK_ERRLOG("broken key\n");
|
||||
return -1;
|
||||
|
Loading…
Reference in New Issue
Block a user