Check isEligibleForAutoCommit when batch input is ended.

Bug: 11951198
Change-Id: Ibbe09fa38eaa3ebf8f9b69f744a29db7ac598975
diff --git a/native/jni/src/defines.h b/native/jni/src/defines.h
index 1969eba..22cc4c0 100644
--- a/native/jni/src/defines.h
+++ b/native/jni/src/defines.h
@@ -311,7 +311,7 @@
 
 // A special value to mean the first word confidence makes no sense in this case,
 // e.g. this is not a multi-word suggestion.
-#define NOT_A_FIRST_WORD_CONFIDENCE (S_INT_MAX)
+#define NOT_A_FIRST_WORD_CONFIDENCE (S_INT_MIN)
 // How high the confidence needs to be for us to auto-commit. Arbitrary.
 // This needs to be the same as CONFIDENCE_FOR_AUTO_COMMIT in BinaryDictionary.java
 #define CONFIDENCE_FOR_AUTO_COMMIT (1000000)