mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-26 09:46:09 +00:00
A better fix for the buffer overflow problem.
Submitted by: guy@device.dyndns.org
This commit is contained in:
parent
5d60900891
commit
e35846b662
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=98622
@ -7,7 +7,7 @@
|
||||
|
||||
PORTNAME= viewfax
|
||||
PORTVERSION= 2.3
|
||||
PORTREVISION= 1
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= comms
|
||||
MASTER_SITES= ftp://ftp.leo.org/pub/comp/os/unix/networking/mgetty/
|
||||
|
||||
|
@ -5,7 +5,7 @@
|
||||
n = *r++;
|
||||
tot += n;
|
||||
+ /* Watch out for buffer overruns, e.g. when n == 65535. */
|
||||
+ if (tot >= pn->width)
|
||||
+ if ( tot > pn->width || LineNum >= pn->height && tot >= pn->width )
|
||||
+ break;
|
||||
if (pix)
|
||||
acc |= (~(t32bits)0 >> nacc);
|
||||
|
Loading…
Reference in New Issue
Block a user