ICU-12913 Add cast to avoid printf compile warning.

X-SVN-Rev: 39688
This commit is contained in:
Andy Heninger 2017-02-18 00:14:37 +00:00
parent 4c2fad3e36
commit 4ff013c080

View file

@ -381,7 +381,7 @@ U_CDECL_END
U_NAMESPACE_BEGIN
Package::Package()
Package::Package()
: doAutoPrefix(FALSE), prefixEndsWithType(FALSE) {
inPkgName[0]=0;
pkgPrefix[0]=0;
@ -1281,7 +1281,7 @@ Package::sortItems() {
}
}
void Package::setItemCapacity(int32_t max)
void Package::setItemCapacity(int32_t max)
{
if(max<=itemMax) {
return;
@ -1289,8 +1289,8 @@ void Package::setItemCapacity(int32_t max)
Item *newItems = (Item*)uprv_malloc(max * sizeof(items[0]));
Item *oldItems = items;
if(newItems == NULL) {
fprintf(stderr, "icupkg: Out of memory trying to allocate %lu bytes for %d items\n",
(unsigned long)max*sizeof(items[0]), max);
fprintf(stderr, "icupkg: Out of memory trying to allocate %lu bytes for %d items\n",
(unsigned long)(max*sizeof(items[0])), max);
exit(U_MEMORY_ALLOCATION_ERROR);
}
if(items && itemCount>0) {