diff options
author | Dmitri Pal <dpal@redhat.com> | 2009-07-22 17:44:15 -0400 |
---|---|---|
committer | Stephen Gallagher <sgallagh@redhat.com> | 2009-08-12 12:24:27 -0400 |
commit | d59ba3139bba2d28c1209f62c01a7017c26dd635 (patch) | |
tree | 21a6b9d3925f07687ef57182ccf8a290f2e63d99 | |
parent | 6fe8b38c66ac922ca1e2a6c9f549f35ed2143a78 (diff) | |
download | sssd-d59ba3139bba2d28c1209f62c01a7017c26dd635.tar.gz sssd-d59ba3139bba2d28c1209f62c01a7017c26dd635.tar.bz2 sssd-d59ba3139bba2d28c1209f62c01a7017c26dd635.zip |
INI Simple fix to properly process multi value config parameters.
Also fixed a typo in the header file.
-rw-r--r-- | common/ini/ini_config.c | 2 | ||||
-rw-r--r-- | common/ini/ini_config.h | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/common/ini/ini_config.c b/common/ini/ini_config.c index e4b1f365..9ef06e55 100644 --- a/common/ini/ini_config.c +++ b/common/ini/ini_config.c @@ -1498,7 +1498,7 @@ char **get_string_config_array(struct collection_item *item, memcpy(dest, start, len); count++; dest += len; - dest = '\0'; + *dest = '\0'; dest++; } diff --git a/common/ini/ini_config.h b/common/ini/ini_config.h index 05ab27df..1fee48ac 100644 --- a/common/ini/ini_config.h +++ b/common/ini/ini_config.h @@ -24,6 +24,7 @@ #define INI_CONFIG_H #include <limits.h> +#include <stdio.h> #include "collection.h" /* Name of the default (missing section in the INI file */ @@ -214,7 +215,7 @@ char *get_bin_config_value(struct collection_item *item, int *length, int *error void free_bin_config_value(char *); /* Array of stings */ -/* Separator sting includes up to three different separators. If NULL comma is assumed. */ +/* Separator string includes up to three different separators. If NULL comma is assumed. */ /* The spaces are trimmed automatically around separators in the string. */ char **get_string_config_array(struct collection_item *item, const char *sep, int *size, int *error); /* Array of long values - separators are detected automatically. */ |