diff options
author | George Hazan <george.hazan@gmail.com> | 2023-11-26 13:11:10 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2023-11-26 13:11:10 +0300 |
commit | 1662a4421fecfdf03e68637e9a5969085644586e (patch) | |
tree | 49a22672b2440fbbdeae448ba0ffae15e42b6626 /protocols/Telegram/src/server.cpp | |
parent | f05405db4308a5c419f15a3c9538e4c11e6c172a (diff) |
for #3964 - reply_id in Telegram, both for messages and files/pictures/etc
Diffstat (limited to 'protocols/Telegram/src/server.cpp')
-rw-r--r-- | protocols/Telegram/src/server.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/protocols/Telegram/src/server.cpp b/protocols/Telegram/src/server.cpp index c846d25666..c3c9bd408c 100644 --- a/protocols/Telegram/src/server.cpp +++ b/protocols/Telegram/src/server.cpp @@ -730,7 +730,7 @@ void CTelegramProto::ProcessMessage(const TD::message *pMessage) if (pMessage->sending_state_->get_id() == TD::messageSendingStatePending::ID)
return;
- char szId[100], szUserId[100];
+ char szId[100], szUserId[100], szReplyId[100];
_i64toa(pMessage->id_, szId, 10);
if (db_event_getById(m_szModuleName, szId))
return;
@@ -760,6 +760,10 @@ void CTelegramProto::ProcessMessage(const TD::message *pMessage) pre.flags |= PREF_SENT;
if (GetGcUserId(pUser, pMessage, szUserId))
pre.szUserId = szUserId;
+ if (pMessage->reply_to_message_id_) {
+ _i64toa(pMessage->reply_to_message_id_, szReplyId, 10);
+ pre.szReplyId = szReplyId;
+ }
ProtoChainRecvMsg(GetRealContact(pUser), &pre);
}
|