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

Fix just-introduced bug in BDATE @-code.

Truncating. str is a pointer, so sizeof(str) is only 4 (or 8) bytes.
parent 34c23c9a
Branches
Tags
No related merge requests found
......@@ -822,7 +822,7 @@ const char* sbbs_t::atcode(char* sp, char* str, size_t maxlen, long* pmode, bool
return(client_name);
if(!strcmp(sp,"BDATE"))
return getbirthdstr(&cfg, useron.birth, str, sizeof(str));
return getbirthdstr(&cfg, useron.birth, str, maxlen);
if(!strcmp(sp,"AGE")) {
safe_snprintf(str,maxlen,"%u",getage(&cfg,useron.birth));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment