david/ipxe
david
/
ipxe
Archived
1
0
Fork 0
Commit Graph

6 Commits

Author SHA1 Message Date
Michael Brown b6ee89ffb5 [legal] Relicense files under GPL2_OR_LATER_OR_UBDL
Relicense files for which I am the sole author (as identified by
util/relicense.pl).

Signed-off-by: Michael Brown <mcb30@ipxe.org>
2015-03-02 14:17:31 +00:00
Michael Brown a32b1e9e35 [libc] Rewrite strtoul()
The implementation of strtoul() has a partially unknown provenance.
Rewrite this code to avoid potential licensing uncertainty.

Since we now use -ffunction-sections, there is no need to place
strtoull() in a separate file from strtoul().

Signed-off-by: Michael Brown <mcb30@ipxe.org>
2015-02-19 16:00:01 +00:00
Michael Brown cd8273b308 [test] Add self-tests for more string functions
Signed-off-by: Michael Brown <mcb30@ipxe.org>
2015-02-16 23:16:20 +00:00
Michael Brown 2b4be69eee [libc] Prevent strndup() from reading beyond the end of the string
strndup() may be called on a string which is not NUL-terminated.  Use
strnlen() instead of strlen() to ensure that we do not read beyond the
end of such a string.

Add self-tests for strndup(), including a test case with an
unterminated string.

Originally-fixed-by: Marin Hannache <git@mareo.fr>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
2014-05-18 21:09:49 +01:00
Michael Brown 5249368950 [test] Add self-tests for strdup()
Signed-off-by: Michael Brown <mcb30@ipxe.org>
2014-05-18 20:39:58 +01:00
Michael Brown 520323e360 [test] Add self-tests for string functions
Signed-off-by: Michael Brown <mcb30@ipxe.org>
2012-11-12 16:58:49 +00:00