diff options
| author | Nick Kralevich <nnk@google.com> | 2012-12-10 10:31:56 -0800 |
|---|---|---|
| committer | Android Git Automerger <android-git-automerger@android.com> | 2012-12-10 10:31:56 -0800 |
| commit | c0ffba907f6ab539ced94e089ccb4abbf7c2808f (patch) | |
| tree | 0591a51b3948635c2e74f5291e138fdfe2f7f5c1 /core | |
| parent | 5fe65556c532c3d51ede4ad794dc886b382ea42c (diff) | |
| parent | 261bc70411ba1dd58654c4eb1c91acbbcfb49060 (diff) | |
| download | frameworks_base-c0ffba907f6ab539ced94e089ccb4abbf7c2808f.zip frameworks_base-c0ffba907f6ab539ced94e089ccb4abbf7c2808f.tar.gz frameworks_base-c0ffba907f6ab539ced94e089ccb4abbf7c2808f.tar.bz2 | |
am 261bc704: Merge "convert jint to uint32_t."
* commit '261bc70411ba1dd58654c4eb1c91acbbcfb49060':
convert jint to uint32_t.
Diffstat (limited to 'core')
| -rw-r--r-- | core/jni/android_util_EventLog.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/jni/android_util_EventLog.cpp b/core/jni/android_util_EventLog.cpp index a3981ce..6ee504d 100644 --- a/core/jni/android_util_EventLog.cpp +++ b/core/jni/android_util_EventLog.cpp @@ -71,8 +71,8 @@ static jint android_util_EventLog_writeEvent_String(JNIEnv* env, jobject clazz, // Don't throw NPE -- I feel like it's sort of mean for a logging function // to be all crashy if you pass in NULL -- but make the NULL value explicit. const char *str = value != NULL ? env->GetStringUTFChars(value, NULL) : "NULL"; - jint len = strlen(str); - const int max = sizeof(buf) - sizeof(len) - 2; // Type byte, final newline + uint32_t len = strlen(str); + size_t max = sizeof(buf) - sizeof(len) - 2; // Type byte, final newline if (len > max) len = max; buf[0] = EVENT_TYPE_STRING; |
