[coreboot] Patch to fix MAX_PATH in lar

Myles Watson mylesgw at gmail.com
Wed Feb 27 20:04:15 CET 2008

This patch addresses Peter's concerns about the safety of path lengths
with directory handling in lar.  If this gets acked, I'll refactor my
original lar directory handling patch to use this.

The changes are all in util/lar/lib.c
      use MAX_PATHLEN instead of defining a new MAX_PATH
      do the math before any string operations and fail if the new
name will be larger than MAX_PATHLEN
      use strcpy and strcat since we know it's safe.


Signed-off-by: Myles Watson <mylesgw at gmail.com>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: max_path.patch
Type: text/x-patch
Size: 1208 bytes
Desc: not available
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20080227/8710f456/attachment.patch>

More information about the coreboot mailing list