Index: source/common/ucnv_ext.cpp |
diff --git a/source/common/ucnv_ext.cpp b/source/common/ucnv_ext.cpp |
index 5cd1ab6174737c535431e0bb25dcc4c7b84e4d38..f8605187240159d6c4c87db9abc4e1dfe53f35b4 100644 |
--- a/source/common/ucnv_ext.cpp |
+++ b/source/common/ucnv_ext.cpp |
@@ -1,7 +1,9 @@ |
+// Copyright (C) 2016 and later: Unicode, Inc. and others. |
+// License & terms of use: http://www.unicode.org/copyright.html |
/* |
****************************************************************************** |
* |
-* Copyright (C) 2003-2013, International Business Machines |
+* Copyright (C) 2003-2016, International Business Machines |
* Corporation and others. All Rights Reserved. |
* |
****************************************************************************** |
@@ -690,10 +692,13 @@ ucnv_extWriteFromU(UConverter *cnv, const int32_t *cx, |
switch(length) { |
case 3: |
*p++=(uint8_t)(value>>16); |
- case 2: /*fall through*/ |
+ U_FALLTHROUGH; |
+ case 2: |
*p++=(uint8_t)(value>>8); |
- case 1: /*fall through*/ |
+ U_FALLTHROUGH; |
+ case 1: |
*p++=(uint8_t)value; |
+ U_FALLTHROUGH; |
default: |
break; /* will never occur */ |
} |
@@ -880,7 +885,7 @@ ucnv_extContinueMatchFromU(UConverter *cnv, |
} else { |
/* the match did not use all of preFromU[] - keep the rest for replay */ |
int32_t length=cnv->preFromULength-match; |
- uprv_memmove(cnv->preFromU, cnv->preFromU+match, length*U_SIZEOF_UCHAR); |
+ u_memmove(cnv->preFromU, cnv->preFromU+match, length); |
cnv->preFromULength=(int8_t)-length; |
} |