TIP: Click on subject to list as thread! ANSI
echo: sync_programming
to: Git commit to main/sbbs/m
from: Deuc
date: 2025-01-01 22:43:00
subject: src/sftp/sftp_attr.c

https://gitlab.synchro.net/main/sbbs/-/commit/13e8739cb615b294bf243988
Modified Files:
	src/sftp/sftp_attr.c
Log Message:
Another Coverity "fix"...

This is kinda valid... I am reading a 32-bit integer from a socket,
then trying to loop that many times.  What Coverity didn't notice
though is that the loop will exit way before due to the buffer
being exhausted.

By ensuring that it's less than UINT32_MAX/4, I'm still not really
enforcing anything since with the 32-bit value for extcnt, and a
32-bit value for every string, there could only be strings before
it failed anyway, even with a 4GB buffer (which you couldn't do).
--- SBBSecho 3.23-Linux
                                                      
* Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)

SOURCE: echomail via QWK@pharcyde.org

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.