From afde0fdcc6bdb88d6a3506632e9a41ad868a77ea Mon Sep 17 00:00:00 2001 From: levlam Date: Sun, 28 Jan 2018 09:18:17 +0300 Subject: [PATCH] Java-binding: remove crash on invalid String encoding. GitOrigin-RevId: c29f8abdd4207eabf422c01ae67b5d1c73ff6ae8 --- td/tl/tl_jni_object.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/td/tl/tl_jni_object.cpp b/td/tl/tl_jni_object.cpp index a93ca546b..7c081d144 100644 --- a/td/tl/tl_jni_object.cpp +++ b/td/tl/tl_jni_object.cpp @@ -107,7 +107,7 @@ static size_t get_utf8_from_utf16_length(const jchar *p, jsize len) { } } - LOG(FATAL) << "Receive wrong UTF-16 string"; + // TODO wrong UTF-16, it is possible return 0; } result += 1 + (cur >= 0x80) + (cur >= 0x800);