Skip to content
Snippets Groups Projects
Commit fea318b3 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Fix a couple typos and file.ini save path issue

parent 0d88dcf1
Branches
Tags
No related merge requests found
......@@ -160,7 +160,7 @@ BOOL read_main_cfg(scfg_t* cfg, char* error, size_t maxerrlen)
SAFECOPY(cfg->new_genders, iniGetString(ini, section, "gender_options", "MFX", value));
SAFECOPY(cfg->new_pass, iniGetString(ini, section, "password", "", value));
SAFECOPY(cfg->new_magic, iniGetString(ini, section, "magic", "", value));
SAFECOPY(cfg->new_magic, iniGetString(ini, section, "magic_word", "", value));
SAFECOPY(cfg->new_sif, iniGetString(ini, section, "sif", "", value));
SAFECOPY(cfg->new_sof, iniGetString(ini, section, "sof", cfg->new_sif, value));
cfg->new_prot = *iniGetString(ini, section, "download_protocol", " ", value);
......
......@@ -638,7 +638,7 @@ BOOL write_file_cfg(scfg_t* cfg, int backup_level)
continue;
if (cfg->dir[i]->lib == j) {
cfg->dir[i]->dirnum = dirnum++;
SAFEPRINTF2(tmp, "lib:%s:%s"
SAFEPRINTF2(tmp, "dir:%s:%s"
,cfg->lib[j]->sname, cfg->dir[i]->code_suffix);
section = tmp;
iniSetString(&ini, section, "description", cfg->dir[i]->lname, NULL);
......@@ -708,6 +708,7 @@ BOOL write_file_cfg(scfg_t* cfg, int backup_level)
iniSetString(&ini, section, "ars", cfg->txtsec[i]->arstr, NULL);
}
SAFEPRINTF(path, "%sfile.ini", cfg->ctrl_dir);
FILE* fp = fopen(path, "w");
if(fp != NULL) {
result = iniWriteFile(fp, ini);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment