From 00dd9e180a7bdcbb41a4247383ea956367b56a60 Mon Sep 17 00:00:00 2001 From: satok Date: Wed, 12 May 2010 11:54:28 +0900 Subject: [PATCH] Fix NPE Change-Id: Ic438704af64e8ebcecba13dbc0f3e72b14ac6f4f --- java/src/com/android/inputmethod/latin/LatinImeLogger.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/java/src/com/android/inputmethod/latin/LatinImeLogger.java b/java/src/com/android/inputmethod/latin/LatinImeLogger.java index c03d1a7ef..c03e7d01c 100644 --- a/java/src/com/android/inputmethod/latin/LatinImeLogger.java +++ b/java/src/com/android/inputmethod/latin/LatinImeLogger.java @@ -284,10 +284,8 @@ public class LatinImeLogger implements SharedPreferences.OnSharedPreferenceChang public static void logOnAutoSuggestion(String before, String after) { if (sLogEnabled) { String[] strings = new String[] {before, after}; - synchronized (sLastAutoSuggestBefore) { + synchronized (LatinImeLogger.class) { sLastAutoSuggestBefore = before; - } - synchronized (sLastAutoSuggestAfter) { sLastAutoSuggestAfter = after; } sLatinImeLogger.sendLogToDropBox(ID_AUTOSUGGESTIONCANCELED, strings);