Skip to content
Snippets Groups Projects
Commit 1c91506a authored by rswindell's avatar rswindell
Browse files

Fix weird compile error triggered by *some* revisions of msvc which dont'

like a str_list_t declared in line (but the char* is fine?!).
parent e60e8442
No related branches found
No related tags found
No related merge requests found
......@@ -3244,11 +3244,12 @@ BOOL DLLCALL user_get_property(scfg_t* scfg, unsigned user_number, const char* s
BOOL DLLCALL user_set_property(scfg_t* scfg, unsigned user_number, const char* section, const char* key, const char* value)
{
FILE* fp;
str_list_t ini;
fp = user_ini_open(scfg, user_number, /* create: */TRUE);
if(fp == NULL)
return FALSE;
str_list_t ini = iniReadFile(fp);
ini = iniReadFile(fp);
char* result = iniSetValue(&ini, section, key, value, /* style */NULL);
iniWriteFile(fp, ini);
iniFreeStringList(ini);
......@@ -3259,11 +3260,12 @@ BOOL DLLCALL user_set_property(scfg_t* scfg, unsigned user_number, const char* s
BOOL DLLCALL user_set_time_property(scfg_t* scfg, unsigned user_number, const char* section, const char* key, time_t value)
{
FILE* fp;
str_list_t ini;
fp = user_ini_open(scfg, user_number, /* create: */TRUE);
if(fp == NULL)
return FALSE;
str_list_t ini = iniReadFile(fp);
ini = iniReadFile(fp);
char* result = iniSetDateTime(&ini, section, key, /* include_time */TRUE, value, /* style */NULL);
iniWriteFile(fp, ini);
iniFreeStringList(ini);
......@@ -3271,4 +3273,4 @@ BOOL DLLCALL user_set_time_property(scfg_t* scfg, unsigned user_number, const ch
return result != NULL;
}
#endif /* !NO_SOCKET_SUPPORT */
\ No newline at end of file
#endif /* !NO_SOCKET_SUPPORT */
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment