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

ftell() can return negative, deal

CID 33232
parent a03d1d37
No related branches found
No related tags found
1 merge request!463MRC mods by Codefenix (2024-10-20)
......@@ -4198,8 +4198,8 @@ void sbbs_t::catsyslog(int crash)
return;
}
}
length=(long)ftell(logfile_fp);
if(length) {
length = ftell(logfile_fp);
if(length > 0) {
if((buf=(char *)malloc(length))==NULL) {
errormsg(WHERE,ERR_ALLOC,str,length);
return;
......
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