mirror of
https://github.com/Tha14/toxic.git
synced 2024-11-12 23:33:03 +01:00
null check just incase
This commit is contained in:
parent
9e2fde8d84
commit
da6ef159e6
@ -422,7 +422,11 @@ void prompt_init_statusbar(ToxWindow *self, Tox *m)
|
||||
uint8_t statusmsg[MAX_STR_SIZE];
|
||||
strcpy(ver, TOXICVER);
|
||||
uint8_t *toxic_ver = strtok(ver, "_");
|
||||
snprintf(statusmsg, MAX_STR_SIZE, "Toxing on Toxic v.%s", toxic_ver);
|
||||
|
||||
if (toxic_ver != NULL)
|
||||
snprintf(statusmsg, MAX_STR_SIZE, "Toxing on Toxic v.%s", toxic_ver);
|
||||
else
|
||||
snprintf(statusmsg, MAX_STR_SIZE, "Toxing on Toxic hacker edition");
|
||||
|
||||
m_set_statusmessage(m, statusmsg, strlen(statusmsg) + 1);
|
||||
snprintf(statusbar->statusmsg, sizeof(statusbar->statusmsg), "%s", statusmsg);
|
||||
|
Loading…
Reference in New Issue
Block a user