summaryrefslogtreecommitdiff
path: root/server/src/saxparser.cc
diff options
context:
space:
mode:
Diffstat (limited to 'server/src/saxparser.cc')
-rw-r--r--server/src/saxparser.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/server/src/saxparser.cc b/server/src/saxparser.cc
index 2018645..b5fb812 100644
--- a/server/src/saxparser.cc
+++ b/server/src/saxparser.cc
@@ -262,7 +262,7 @@ TEST_BEGIN;
FILE *fp = fopen(XMLFILE, "w");
TEST_NOTEQUAL(fp, NULL, "Test if file \""XMLFILE"\" could be written.");
if(!fp) TEST_FATAL("Could not write "XMLFILE);
-fprintf(fp, xml);
+fprintf(fp, "%s", xml);
fclose(fp);
TEST_MSG("Test callback parser.");
@@ -295,8 +295,8 @@ for(size_t sz = 1; sz < 1000; sz++) {
fp = fopen(XMLFILE, "w");
TEST_NOTEQUAL(fp, NULL, "Test if file \""XMLFILE"\" could be written.");
if(!fp) TEST_FATAL("Could not write "XMLFILE);
-fprintf(fp, xml_notrailingwhitespace);
-fprintf(fp, xml_notrailingwhitespace);
+fprintf(fp, "%s", xml_notrailingwhitespace);
+fprintf(fp, "%s", xml_notrailingwhitespace);
fclose(fp);
TEST_MSG("Test buffer parser with multiple documents in the same buffer.");
@@ -341,7 +341,7 @@ TEST_MSG("Test buffer parser with multiple documents in the same buffer.");
fp = fopen(XMLFILE, "w");
TEST_NOTEQUAL(fp, NULL, "Test if file \""XMLFILE"\" could be written.");
if(!fp) TEST_FATAL("Could not write "XMLFILE);
-fprintf(fp, xml_fail);
+fprintf(fp, "%s", xml_fail);
fclose(fp);
TEST_MSG("Test failure");
@@ -359,7 +359,7 @@ goon:
fp = fopen(XMLFILE, "w");
TEST_NOTEQUAL(fp, NULL, "Test if file \""XMLFILE"\" could be written.");
if(!fp) TEST_FATAL("Could not write "XMLFILE);
-fprintf(fp, xml_fail2);
+fprintf(fp, "%s", xml_fail2);
fclose(fp);
// Test failure