Skip to content
Snippets Groups Projects
Commit d518b015 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Fix negative MSG_SCORE @-code on 64-bit (*nix) builds

As reported by Android8675 (SHODAN) on DOVE-Net.
This problem did not manifest itself in 32-bit builds.
parent 2458bfc3
No related branches found
No related tags found
1 merge request!463MRC mods by Codefenix (2024-10-20)
Pipeline #3230 passed
......@@ -1884,7 +1884,7 @@ const char* sbbs_t::atcode(char* sp, char* str, size_t maxlen, long* pmode, bool
return(str);
}
if(!strcmp(sp,"MSG_SCORE") && current_msg!=NULL) {
safe_snprintf(str, maxlen, "%ld", (long)(current_msg->upvotes - current_msg->downvotes));
safe_snprintf(str, maxlen, "%ld", (long)current_msg->upvotes - (long)current_msg->downvotes);
return(str);
}
if(!strcmp(sp,"MSG_UPVOTES") && current_msg!=NULL) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment