Merge commit '78be0498' into manualmerge
Conflicts: libs/androidfw/ResourceTypes.cpp tools/aapt/Android.mk tools/aapt/StringPool.cpp tools/aapt/StringPool.h Change-Id: I9d69efdfb892032895ace12159d193304f02dc6c
This commit is contained in:
@@ -26,6 +26,7 @@
|
||||
// Set to true for noisy debug output.
|
||||
static const bool kIsDebug = false;
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
void strcpy16_htod(char16_t* dst, const char16_t* src)
|
||||
{
|
||||
while (*src) {
|
||||
@@ -35,6 +36,17 @@ void strcpy16_htod(char16_t* dst, const char16_t* src)
|
||||
}
|
||||
*dst = 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
void strcpy16_htod(uint16_t* dst, const char16_t* src)
|
||||
{
|
||||
while (*src) {
|
||||
uint16_t s = htods(static_cast<uint16_t>(*src));
|
||||
*dst++ = s;
|
||||
src++;
|
||||
}
|
||||
*dst = 0;
|
||||
}
|
||||
|
||||
void printStringPool(const ResStringPool* pool)
|
||||
{
|
||||
@@ -434,7 +446,7 @@ status_t StringPool::writeStringBlock(const sp<AaptFile>& pool)
|
||||
return NO_MEMORY;
|
||||
}
|
||||
|
||||
const size_t charSize = mUTF8 ? sizeof(uint8_t) : sizeof(char16_t);
|
||||
const size_t charSize = mUTF8 ? sizeof(uint8_t) : sizeof(uint16_t);
|
||||
|
||||
size_t strPos = 0;
|
||||
for (i=0; i<STRINGS; i++) {
|
||||
|
||||
Reference in New Issue
Block a user