X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/b331163bffd790ced0e88b73f44f86d49ccc48a5..38fbf2fd31f5cd99b500914d6037b1d06b608645:/icuSources/tools/tzcode/icuzdump.cpp?ds=sidebyside diff --git a/icuSources/tools/tzcode/icuzdump.cpp b/icuSources/tools/tzcode/icuzdump.cpp index b63e877e..3e5ed1de 100644 --- a/icuSources/tools/tzcode/icuzdump.cpp +++ b/icuSources/tools/tzcode/icuzdump.cpp @@ -1,12 +1,14 @@ +// © 2016 and later: Unicode, Inc. and others. +// License & terms of use: http://www.unicode.org/copyright.html /* ******************************************************************************* * -* Copyright (C) 2007-2014, International Business Machines +* Copyright (C) 2007-2016, International Business Machines * Corporation and others. All Rights Reserved. * ******************************************************************************* * file name: icuzdump.cpp -* encoding: US-ASCII +* encoding: UTF-8 * tab size: 8 (not used) * indentation:4 * @@ -34,6 +36,7 @@ #include "unicode/ustream.h" #include "unicode/putil.h" +#include "cmemory.h" #include "uoptions.h" using namespace std; @@ -289,7 +292,7 @@ main(int argc, char *argv[]) { const char *linesep = NULL; U_MAIN_INIT_ARGS(argc, argv); - argc = u_parseArgs(argc, argv, sizeof(options)/sizeof(options[0]), options); + argc = u_parseArgs(argc, argv, UPRV_LENGTHOF(options), options); if (argc < 0) { cerr << "Illegal command line argument(s)" << endl << endl; @@ -384,7 +387,7 @@ main(int argc, char *argv[]) { ofstream* fout = new ofstream(path.str().c_str(), mode); if (fout->fail()) { - cerr << "Cannot open file " << path << endl; + cerr << "Cannot open file " << path.str() << endl; delete fout; delete tz; break;