| Index: source/samples/ucnv/convsamp.cpp
|
| diff --git a/source/samples/ucnv/convsamp.cpp b/source/samples/ucnv/convsamp.cpp
|
| index fb17f500038ae5c04b579a127c29d8bcf873a822..139e948efe356d3d293f21362b8ce8be47d3bd15 100644
|
| --- a/source/samples/ucnv/convsamp.cpp
|
| +++ b/source/samples/ucnv/convsamp.cpp
|
| @@ -1,6 +1,12 @@
|
| -/**************************************************************************
|
| +/*************************************************************************
|
| *
|
| -* Copyright (C) 2000-2013, International Business Machines
|
| +* Copyright (C) 2016 and later: Unicode, Inc. and others.
|
| +* License & terms of use: http://www.unicode.org/copyright.html#License
|
| +*
|
| +**************************************************************************
|
| +**************************************************************************
|
| +*
|
| +* Copyright (C) 2000-2016, International Business Machines
|
| * Corporation and others. All Rights Reserved.
|
| *
|
| ***************************************************************************
|
| @@ -33,6 +39,7 @@
|
| #include <string.h>
|
| #include <stdlib.h> /* malloc */
|
|
|
| +#include "cmemory.h"
|
| #include "unicode/utypes.h" /* Basic ICU data types */
|
| #include "unicode/ucnv.h" /* C Converter API */
|
| #include "unicode/ustring.h" /* some more string fcns*/
|
| @@ -1086,7 +1093,7 @@ void convsample_50() {
|
| conv = ucnv_open(encoding, &err);
|
| // do the conversion
|
| ucnv_toUnicode(conv,
|
| - &target, output + sizeof(output)/U_SIZEOF_UCHAR,
|
| + &target, output + UPRV_LENGTHOF(output),
|
| &source, input + sizeof(input),
|
| NULL, TRUE, &err);
|
| out = output;
|
|
|