Remove auth_key_id from PacketInfo.

This commit is contained in:
levlam 2023-09-08 19:18:38 +03:00
parent 31f778e040
commit a1d0808d9f
2 changed files with 1 additions and 3 deletions

View File

@ -13,7 +13,6 @@ namespace mtproto {
struct PacketInfo {
enum { Common, EndToEnd } type = Common;
uint64 auth_key_id{0};
uint32 message_ack{0};
uint64 salt{0};

View File

@ -443,8 +443,7 @@ Result<Transport::ReadResult> Transport::read(MutableSlice message, const AuthKe
}
}
info->auth_key_id = as<int64>(message.begin());
info->no_crypto_flag = info->auth_key_id == 0;
info->no_crypto_flag = as<int64>(message.begin()) == 0;
MutableSlice data;
if (info->type == PacketInfo::EndToEnd) {
TRY_STATUS(read_e2e_crypto(message, auth_key, info, &data));