Commit Graph

12203 Commits

Author SHA1 Message Date
levlam
e52d08da74 Use PublicRsaKeyInterface in AuthDataShared. 2024-01-22 01:55:16 +03:00
levlam
d5c3456085 Remove default NerQueryDispatcher constructor. 2024-01-22 01:39:31 +03:00
levlam
b4c075593e Log received message info. 2024-01-21 01:50:20 +03:00
levlam
674b380bd5 Never ask for ack for service queries. 2024-01-21 01:31:24 +03:00
levlam
942e5fc613 Add LambdaPromise debug. 2024-01-20 12:54:17 +03:00
levlam
1147dfc6fb Remove unused format::lambda. 2024-01-20 12:05:49 +03:00
levlam
09c6bad8bd Remove pinned message notification only if new pinned message is added to Mentions. 2024-01-20 03:30:10 +03:00
levlam
2a9393ff7a Add "process_pinned_messages_as_mentions" option to allow keep previous behavior. 2024-01-19 22:23:26 +03:00
levlam
121fbe535f Create dependent chats right after Message object creation. 2024-01-18 15:21:44 +03:00
levlam
021c0bd02d Improve logging. 2024-01-18 14:59:53 +03:00
levlam
e5f9e4c400 Decrease UPDATE_APPLY_WARNING_TIME and improve logging. 2024-01-17 16:50:08 +03:00
levlam
14c93b1772 Fix added_message_full_id initialization. 2024-01-16 21:40:25 +03:00
levlam
6d910597e5 Delete message from map after using. 2024-01-16 21:36:24 +03:00
levlam
c2277a1044 Add source to get_user_full_force. 2024-01-15 14:12:00 +03:00
Liru Færs
0f98d76683
Fix DialogActionManager::send_dialog_action in secret chats (#2756)
* Fix DialogActionManager::send_dialog_action in secret chats 

The code in `DialogActionManager::send_dialog_action` made the assumption that since we'd either have early returned or `DialogManager::have_input_peer` would be true, and therefore the else block of the conditional, which intended to set input_peer, should have done so successfully.

However, `DialogManager::have_input_peer` will return true for secret chats when `contacts_manager->have_input_encrypted_peer`
And `DialogManager::get_input_peer` will return a `nullptr` for secret chats by design (I believe this is because they operate using structures that are currently incompatible)

This should fix the root of a crash that happens when typing in or sending messages to secret chats on:
Telegram X 0.26.4.1678-arm64-v8a (99b10675)
TDLib: 1.8.23 (tdlib/td@4bafdc2)

* Move CHECK below SecretChat case instead per feedback
2024-01-15 01:02:56 +03:00
levlam
58c457ab5f Add NotificationManager::parse_push_notification_attach. 2024-01-14 23:05:35 +03:00
levlam
3e8d368ba5 Add NotificationManager::add_push_notification_user. 2024-01-14 22:52:52 +03:00
levlam
ffdb02374e Simplify Manager actor reset. 2024-01-13 02:08:28 +03:00
levlam
916e5de43e Simplify code for manager reset. 2024-01-13 01:28:15 +03:00
levlam
96fee82699 Use separate initialization functions for different Manager types. 2024-01-13 00:59:17 +03:00
levlam
8b97d2e8e4 Move binlog events processing to Td::process_binlog_events. 2024-01-13 00:42:49 +03:00
levlam
0aa8816c28 Don't always treat pins as mentions. 2024-01-12 18:15:19 +03:00
levlam
4bafdc2b71 Fix MessagesManager::drop_dialog_last_pinned_message_id. 2024-01-12 12:16:51 +03:00
levlam
5d7c69d0d1 Remove CallManager::Update typedef. 2024-01-11 13:36:38 +03:00
levlam
9413360255 Improve SplitSource.php. 2024-01-11 02:08:43 +03:00
levlam
d029eff807 Minor improvements. 2024-01-11 00:12:16 +03:00
levlam
21418140bd Fix removal of message reply for failed to send forwarded messages. 2024-01-10 22:01:39 +03:00
levlam
a10f03cde1 Add sanity check. 2024-01-10 21:41:13 +03:00
levlam
5e0301db45 Improve fatal error message on app downgrade. 2024-01-10 21:20:17 +03:00
levlam
17a412a04a Don't delete notifications when initializing last_new_message_id. There should be no old notifications anyway (2). 2024-01-10 21:08:43 +03:00
levlam
bc5b1f4e19 Remove unavailable messages from the list of linked messages. 2024-01-10 20:22:45 +03:00
levlam
509908edda Don't register users/channels in unknown channels. 2024-01-10 20:07:56 +03:00
levlam
7f844b637f Correctly update self speculative channel status while joining it. 2024-01-10 18:03:41 +03:00
levlam
1fa64892e1 Don't count non-member creator in administrator count. 2024-01-10 17:49:17 +03:00
levlam
44eba3d214 Combine JoinChannel queries. 2024-01-10 17:42:14 +03:00
levlam
faee94b680 Apply message auto-delete time from chat creation message. 2024-01-10 17:20:13 +03:00
levlam
4d51b2c875 Move create_new_chat/create_new_channel to ContactsManager. 2024-01-10 17:09:09 +03:00
levlam
a409af0973 Move migrate_dialog_to_megagroup to ContactsManager. 2024-01-10 15:57:19 +03:00
levlam
1bc8e90c10 Move create_new_secret_chat to ContactsManager. 2024-01-10 15:20:16 +03:00
levlam
da031b3faa Allow \r and other empty entities as a separator between MarkdownV2 blockquotes. 2024-01-10 14:36:27 +03:00
levlam
ce8a4b6d21 tg_cli: use preset message_thread_id_ in requests where it is optional. 2024-01-10 13:16:37 +03:00
levlam
c6154c43aa Don't store message interaction info for bots. 2024-01-09 10:59:24 +03:00
levlam
3817f2cb6b Minor improvements. 2024-01-08 19:26:34 +03:00
levlam
7b6ce8b822 Move reload_dialog_info to DialogManager. 2024-01-08 19:20:22 +03:00
levlam
9a90089879 Move check_dialog_username to DialogManager. 2024-01-08 19:14:41 +03:00
levlam
466c841b4e Move send_update_add_chat_members_privacy_forbidden to DialogParticipantManager. 2024-01-08 18:57:44 +03:00
levlam
127b7ad086 Add DialogParticipantManager::speculative_add_channel_user. 2024-01-08 18:50:18 +03:00
levlam
b1d72276a7 Move set_channel_participant_status and similar methods to DialogParticipantManager. 2024-01-08 18:44:13 +03:00
levlam
9660a7f2b1 Move set_dialog_participant_status and similar methods to DialogParticipantManager. 2024-01-08 18:15:21 +03:00
levlam
50b5a6e9bf Move channel participant cache to DialogParticipantManager. 2024-01-08 18:03:04 +03:00