Commit 2adf52b8 authored by Alexander Barkov's avatar Alexander Barkov

Fixing ini.test failure on Linux:

No need to print "\n" before the very first section.

modified:
  storage/connect/inihandl.c
parent 237eda72
...@@ -183,10 +183,13 @@ static void PROFILE_CopyEntry( char *buffer, const char *value, uint len, ...@@ -183,10 +183,13 @@ static void PROFILE_CopyEntry( char *buffer, const char *value, uint len,
static void PROFILE_Save( FILE *file, PROFILESECTION *section ) static void PROFILE_Save( FILE *file, PROFILESECTION *section )
{ {
PROFILEKEY *key; PROFILEKEY *key;
int secno;
for (; section; section = section->next) { for (secno= 0; section; section= section->next) {
if (section->name[0]) if (section->name[0]) {
fprintf(file, "\n[%s]\n", SVP(section->name)); fprintf(file, "%s[%s]\n", secno ? "\n" : "", SVP(section->name));
secno++;
}
for (key = section->key; key; key = key->next) for (key = section->key; key; key = key->next)
if (key->name && key->name[0]) { if (key->name && key->name[0]) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment