Mercurial > hg > nnchat
comparison th_config.c @ 135:26fe4dab7e78
Cleanup.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Sat, 30 Oct 2010 21:08:21 +0300 |
parents | ffe8bbd429fa |
children | 3e221c16b087 |
comparison
equal
deleted
inserted
replaced
134:f367fc14021a | 135:26fe4dab7e78 |
---|---|
617 break; | 617 break; |
618 | 618 |
619 case ITEM_SECTION: | 619 case ITEM_SECTION: |
620 { | 620 { |
621 int res; | 621 int res; |
622 if (fprintf(f->file, "\n%s = {\n", item->name) < 0) | 622 if (fprintf(f->file, "%s = {\n", item->name) < 0) |
623 return -7; | 623 return -7; |
624 res = th_cfg_write_sect(f, (cfgitem_t *) item->data, nesting + 1); | 624 res = th_cfg_write_sect(f, (cfgitem_t *) item->data, nesting + 1); |
625 if (res != 0) return res; | 625 if (res != 0) return res; |
626 if (fprintf(f->file, "} # End of '%s'\n\n", item->name) < 0) | 626 if (fprintf(f->file, "}\n\n") < 0) |
627 return -8; | 627 return -8; |
628 } | 628 } |
629 break; | 629 break; |
630 | 630 |
631 case ITEM_HEX_TRIPLET: | 631 case ITEM_HEX_TRIPLET: |