NAME
libnvmf_config_emit_install - Write a configuration to disk.
SYNOPSIS
int libnvmf_config_emit_install (struct libnvmf_config_emitter *emitter , const char *file , bool force );
ARGUMENTS
- emitter
-
Configuration emitter.
- file
-
Destination configuration file, or NULL to use the default configuration file.
- force
-
Overwrite an existing configuration if true.
DESCRIPTION
The default persona is written to the main configuration file. Each named persona is written to a separate drop-in file.
The generated configuration is validated by reading it back through the standard parser before it is installed. Files are written atomically (temporary file followed by rename). If any step fails, no configuration is installed.
RETURN
* 0 on success. * -EEXIST if a configuration already exists and force is false. * -EINVAL if emitter is NULL. * A negative errno value on other failures.