Skip to content
This repository has been archived by the owner on Nov 2, 2023. It is now read-only.

getForwardMsg 返回3打头的10位qq号时溢出成了负数 #281

Closed
SalimTerryLi opened this issue Jan 2, 2022 · 1 comment
Closed
Labels
bug Something isn't working

Comments

@SalimTerryLi
Copy link

Node.js Version

v16.13.1

Package Version

2.1.8

Login Protocol

Android

Bug Description

使用群对象的getMemberMap()得到的某位群老哥的qq号是正常的3开头的十位qq,但将他的消息合并转发后,再使用getForwardMsg()获取到的消息对象的user_id变成了一个负数。取负数的绝对值和他原qq号相加刚好是2^32,看起来像是int32溢出了

Log Details

No response

@takayama-lily takayama-lily added the bug Something isn't working label Jan 2, 2022
@takayama-lily
Copy link
Owner

临时解决方案:无符号右移
user_id>>>0

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants