mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
parent
865b1a915c
commit
c0e2b91fe8
|
@ -764,6 +764,8 @@ void Core::removeGroup(int groupId, bool fake)
|
||||||
QString Core::getUsername() const
|
QString Core::getUsername() const
|
||||||
{
|
{
|
||||||
QString sname;
|
QString sname;
|
||||||
|
if (!tox)
|
||||||
|
return sname;
|
||||||
int size = tox_self_get_name_size(tox);
|
int size = tox_self_get_name_size(tox);
|
||||||
uint8_t* name = new uint8_t[size];
|
uint8_t* name = new uint8_t[size];
|
||||||
tox_self_get_name(tox, name);
|
tox_self_get_name(tox, name);
|
||||||
|
@ -830,6 +832,8 @@ QPair<QByteArray, QByteArray> Core::getKeypair() const
|
||||||
QString Core::getStatusMessage() const
|
QString Core::getStatusMessage() const
|
||||||
{
|
{
|
||||||
QString sname;
|
QString sname;
|
||||||
|
if (!tox)
|
||||||
|
return sname;
|
||||||
size_t size = tox_self_get_status_message_size(tox);
|
size_t size = tox_self_get_status_message_size(tox);
|
||||||
uint8_t* name = new uint8_t[size];
|
uint8_t* name = new uint8_t[size];
|
||||||
tox_self_get_status_message(tox, name);
|
tox_self_get_status_message(tox, name);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user