X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/2ca993e82fb37b597a3c73ecd1586a139a6579c5..340931cb2e044a2141d11567dd0f782524e32994:/icuSources/test/iotest/filetst.c diff --git a/icuSources/test/iotest/filetst.c b/icuSources/test/iotest/filetst.c index 8cae202d..e074b902 100644 --- a/icuSources/test/iotest/filetst.c +++ b/icuSources/test/iotest/filetst.c @@ -1,10 +1,12 @@ +// © 2016 and later: Unicode, Inc. and others. +// License & terms of use: http://www.unicode.org/copyright.html /* ********************************************************************** * Copyright (C) 2004-2016, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * file name: filetst.c - * encoding: US-ASCII + * encoding: UTF-8 * tab size: 8 (not used) * indentation:4 * @@ -729,7 +731,7 @@ static void TestfgetsNewLineHandling(void) { static void TestLineCount(const char *prefixLine, const char *line, int32_t numRepititions) { UChar buffer[64]; UChar expectedBuffer[64]; - int32_t lineLen = strlen(line); + int32_t lineLen = (int32_t)strlen(line); UChar *returnedUCharBuffer; int32_t repetitions; UFILE *myFile = NULL; @@ -1118,7 +1120,7 @@ static void TestFilePrintCompatibility(void) { } #endif -#define TestFPrintFormat(uFormat, uValue, cFormat, cValue) \ +#define TestFPrintFormat(uFormat, uValue, cFormat, cValue) UPRV_BLOCK_MACRO_BEGIN { \ myFile = u_fopen(STANDARD_TEST_FILE, "w", STANDARD_TEST_LOCALE, NULL);\ if (myFile == NULL) {\ log_err("Can't write test file for %s.\n", uFormat);\ @@ -1144,6 +1146,7 @@ static void TestFilePrintCompatibility(void) { if (buffer[uNumPrinted+1] != '*') {\ log_err("%" uFormat " too much stored\n");\ }\ +} UPRV_BLOCK_MACRO_END #if !UCONFIG_NO_FORMATTING static void TestFprintfFormat(void) { @@ -1379,6 +1382,7 @@ static void TestFScanset(void) { #endif #if !UCONFIG_NO_FORMATTING static void TestBadFScanfFormat(const char *format, const UChar *uValue, const char *cValue) { + (void)cValue; // suppress compiler warnings about unused variable UFILE *myFile; UChar uBuffer[256]; int32_t uNumScanned;