mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-05 05:25:34 +00:00
Cast U_MAX_PTR to some type. 'void' has no size!
X-Trac-URL: https://ssl.icu-project.org/trac/ticket/52 git-svn-id: http://source.icu-project.org/repos/icu/icu/trunk@123 0a8b766c-62c9-45f9-954d-7f2943c9ead0
This commit is contained in:
parent
5c049361b0
commit
39dda40d7d
2 changed files with 3 additions and 3 deletions
|
@ -745,7 +745,7 @@ int32_t ucnv_fromUChars (const UConverter * converter,
|
|||
myTarget_limit = target + targetSize;
|
||||
|
||||
if(myTarget_limit < target) /*if targetsize is such that the limit*/
|
||||
myTarget_limit = U_MAX_PTR; /* would wrap around, truncate it. */
|
||||
myTarget_limit = (char *)U_MAX_PTR; /* would wrap around, truncate it. */
|
||||
|
||||
if (targetSize > 0)
|
||||
{
|
||||
|
@ -853,7 +853,7 @@ int32_t ucnv_toUChars (const UConverter * converter,
|
|||
myTarget_limit = target + targetSize - 1;
|
||||
|
||||
if(myTarget_limit < target) /*if targetsize is such that the limit*/
|
||||
myTarget_limit = U_MAX_PTR - 1; /* would wrap around, truncate it. */
|
||||
myTarget_limit = ((UChar*)U_MAX_PTR) - 1; /* would wrap around, truncate it. */
|
||||
|
||||
|
||||
/*Not in pure pre-flight mode */
|
||||
|
|
|
@ -785,7 +785,7 @@ UnicodeString::extract(UTextOffset start,
|
|||
myTargetLimit = myTarget + arraySize;
|
||||
|
||||
if(myTargetLimit < myTarget) /* ptr wrapped around: pin to U_MAX_PTR */
|
||||
myTargetLimit = U_MAX_PTR;
|
||||
myTargetLimit = (char*)U_MAX_PTR;
|
||||
|
||||
// perform the conversion
|
||||
// there is no loop here since we assume the buffer is large enough
|
||||
|
|
Loading…
Add table
Reference in a new issue