aboutsummaryrefslogtreecommitdiffstats
path: root/conf.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>1998-08-18 03:58:14 +0000
committerEric S. Raymond <esr@thyrsus.com>1998-08-18 03:58:14 +0000
commitd7e2c56ecb63526c6549c92564e5fdb581671870 (patch)
tree09530e4d2dcf767e973d86fc1cd34d9bba426e73 /conf.c
parent0d42f5b7ddda363496f087e97a250947a953154c (diff)
downloadfetchmail-d7e2c56ecb63526c6549c92564e5fdb581671870.tar.gz
fetchmail-d7e2c56ecb63526c6549c92564e5fdb581671870.tar.bz2
fetchmail-d7e2c56ecb63526c6549c92564e5fdb581671870.zip
Enclose string dumps in doublequotes to work with visbuf properly.
svn path=/trunk/; revision=2044
Diffstat (limited to 'conf.c')
-rw-r--r--conf.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/conf.c b/conf.c
index e0c76460..837e1c70 100644
--- a/conf.c
+++ b/conf.c
@@ -63,9 +63,9 @@ static void stringdump(const char *name, const char *member)
static char buf[BUFSIZ];
indent('\0');
- fprintf(stdout, "'%s':", name);
+ fprintf(stdout, "\"%s\":", name);
if (member)
- fprintf(stdout, "'%s'", visbuf(member));
+ fprintf(stdout, "\"%s\"", visbuf(member));
else
fputs("None", stdout);
fputs(",\n", stdout);
@@ -92,7 +92,7 @@ static void listdump(const char *name, struct idlist *list)
/* dump a string list member with current indent */
{
indent('\0');
- fprintf(stdout, "'%s':", name);
+ fprintf(stdout, "\"%s\":", name);
if (!list)
fputs("None,\n", stdout);
@@ -104,7 +104,7 @@ static void listdump(const char *name, struct idlist *list)
for (idp = list; idp; idp = idp->next)
if (idp->id)
{
- fprintf(stdout, "'%s'", visbuf(idp->id));
+ fprintf(stdout, "\"%s\"", visbuf(idp->id));
if (idp->next)
fputs(", ", stdout);
}
@@ -237,10 +237,10 @@ void dump_config(struct runctl *runp, struct query *querylist)
for (idp = ctl->localnames; idp; idp = idp->next)
{
if (idp->val.id2)
- fprintf(stdout, "('%s', %s)",
+ fprintf(stdout, "(\"%s\", %s)",
visbuf(idp->id), visbuf(idp->val.id2));
else
- fprintf(stdout, "'%s'", visbuf(idp->id));
+ fprintf(stdout, "\"%s\"", visbuf(idp->id));
if (idp->next)
fputs(", ", stdout);
}