From 276b757e2d2ca8f4782399c933e01bf8224e7005 Mon Sep 17 00:00:00 2001 From: Greyson Parrelli Date: Fri, 7 May 2021 10:17:56 -0400 Subject: [PATCH] Fix the other possible NPE in database migration. --- .../securesms/database/helpers/SQLCipherOpenHelper.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/src/main/java/org/thoughtcrime/securesms/database/helpers/SQLCipherOpenHelper.java b/app/src/main/java/org/thoughtcrime/securesms/database/helpers/SQLCipherOpenHelper.java index 510cf08296..7786e10e06 100644 --- a/app/src/main/java/org/thoughtcrime/securesms/database/helpers/SQLCipherOpenHelper.java +++ b/app/src/main/java/org/thoughtcrime/securesms/database/helpers/SQLCipherOpenHelper.java @@ -1352,6 +1352,10 @@ public class SQLCipherOpenHelper extends SQLiteOpenHelper implements SignalDatab byte[] reactions = cursor.getBlob(cursor.getColumnIndexOrThrow("reactions")); long notifiedTimestamp = cursor.getLong(cursor.getColumnIndexOrThrow("notified_timestamp")); + if (reactions == null) { + continue; + } + try { boolean hasReceiveLaterThanNotified = ReactionList.parseFrom(reactions) .getReactionsList()