Nmap Security Scanner
*Intro
*Ref Guide
*Install Guide
*Download
*Changelog
*Book
*Docs
Security Lists
*Nmap Hackers
*Nmap Dev
*Bugtraq
*Full Disclosure
*Pen Test
*Basics
*More
Security Tools
*Pass crackers
*Sniffers
*Vuln Scanners
*Web scanners
*Wireless
*Exploitation
*Packet crafters
*More
Site News
Site Search:
Exploit World
Advertising
About/Contact
Credits
Sponsors:




bugtraq logo Bugtraq mailing list archives

Re: better snprintf replacement, anyone?
From: alan () LXORGUK UKUU ORG UK (Alan Cox)
Date: Tue, 22 Jul 1997 09:36:35 +0100


you have a large enough buffer, you eliminate the buffer overflow problem,
and you don't truncate the string.  Is malloc()-ing the memory *that*
inefficient?  Less efficient than the scanning and parsing snprintf()
must do to the format string?

In the case of a dynamic loader you don't have a libc backing you, thats
why someone took the (very wrong) shortcut they did originally when doing
ld.so

You are right about malloc for many cases, but its also true that you
normally know the length of a buffer anyway



  By Date           By Thread  

Current thread:
[ Nmap | Sec Tools | Mailing Lists | Site News | About/Contact | Advertising | Privacy ]