X-Git-Url: https://git.liburcu.org/?a=blobdiff_plain;f=tests%2Futils%2Fxml-utils%2Fvalidate_xml.cpp;h=8e30100c0bcf5cd2f11e249d7f3a259d856a61f1;hb=f46376a14da2eb796690cb4e718e8b213839d6ea;hp=bb67e56e17edea75706b56c50ec072c49f2433be;hpb=729c1fec5976af17fded2f026725a08ef1924290;p=lttng-tools.git diff --git a/tests/utils/xml-utils/validate_xml.cpp b/tests/utils/xml-utils/validate_xml.cpp index bb67e56e1..8e30100c0 100644 --- a/tests/utils/xml-utils/validate_xml.cpp +++ b/tests/utils/xml-utils/validate_xml.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2014 Jonathan Rajotte + * Copyright (C) 2014 EfficiOS Inc. * * SPDX-License-Identifier: LGPL-2.1-only * @@ -27,6 +27,8 @@ #include #include +#include + struct validation_ctx { xmlSchemaParserCtxtPtr parser_ctx; xmlSchemaPtr schema; @@ -38,8 +40,9 @@ enum command_err_code { CMD_ERROR }; -static -void xml_error_handler(void *ctx, const char *format, ...) +static ATTR_FORMAT_PRINTF(2, 3) +void xml_error_handler(void *ctx __attribute__((unused)), + const char *format, ...) { char *err_msg; va_list args; @@ -148,7 +151,7 @@ end: } -int main(int argc, char **argv, char *env[]) +int main(int argc, char **argv) { int ret; struct validation_ctx ctx = { 0 };