# HG changeset patch # User David Demelier # Date 1321476033 -3600 # Node ID f028a84bc3f1a7bd5f6466577a0d721eae09b037 # Parent c8bbdbedcf0711cb145624152498a1d394292c88 Fix an error diff -r c8bbdbedcf07 -r f028a84bc3f1 ini.c --- a/ini.c Wed Nov 16 21:28:35 2011 +0100 +++ b/ini.c Wed Nov 16 21:40:33 2011 +0100 @@ -293,9 +293,9 @@ sectionName = NULL; for (i = 0; i < length; ++i) { /* Do not select the same section for performance. */ - if (sectionName == NULL || !strcmp(hdrs[i].section, sectionName)) { + if (sectionName == NULL || strcmp(hdrs[i].section, sectionName) != 0) { sectionName = hdrs[i].section; - section = ini_select_section(config, sectionName); + section = ini_select_section(config, hdrs[i].section); } /* Skip the section if does not exists in the config */