Fixed a buffer overflow when processing TIC files with a lot of garabage in it
This commit is contained in:
parent
6821829f83
commit
06f53854e2
@ -13,6 +13,8 @@ v0.91.8 26-Apr-2007
|
||||
Added mbtask commands to update the MIB counters.
|
||||
Fixed mbfile import with too many description lines in
|
||||
files.bbs
|
||||
Fixed a buffer overflow when processing TIC files with a lot
|
||||
of garbage in it.
|
||||
|
||||
mbnewusr:
|
||||
Fixed loading default language for new user.
|
||||
|
@ -375,8 +375,10 @@ int LoadTic(char *inb, char *tfn, orphans **opl)
|
||||
* If we didn't find a matching keyword it is a line we
|
||||
* will just remember and forward if there are downlinks.
|
||||
*/
|
||||
if (TIC.TicIn.Unknowns < 25) {
|
||||
strcpy(TIC.TicIn.Unknown[TIC.TicIn.Unknowns], Temp);
|
||||
if (strlen(Temp) > 127) {
|
||||
Syslog('+', "Unknown too long TIC line dropped");
|
||||
} else if (TIC.TicIn.Unknowns < 25) {
|
||||
strncpy(TIC.TicIn.Unknown[TIC.TicIn.Unknowns], Temp, 127);
|
||||
TIC.TicIn.Unknowns++;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user