From c3c827cf864b10d5086177602f0157b9596bc380 Mon Sep 17 00:00:00 2001 From: Patrick Georgi Date: Fri, 27 May 2011 15:31:52 +0200 Subject: libpayload: Provide atol(), malloc.h Change-Id: I807ca061115146a6851eef481eb881b279fba8e1 Signed-off-by: Patrick Georgi Reviewed-on: http://review.coreboot.org/86 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer --- payloads/libpayload/libc/string.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'payloads/libpayload/libc/string.c') diff --git a/payloads/libpayload/libc/string.c b/payloads/libpayload/libc/string.c index 2e0a558b20..8c6ea99115 100644 --- a/payloads/libpayload/libc/string.c +++ b/payloads/libpayload/libc/string.c @@ -473,6 +473,11 @@ long int strtol(const char *ptr, char **endptr, int base) return ret * negative; } +long atol(const char *nptr) +{ + return strtol(nptr, NULL, 10); +} + /** * Convert the initial portion of a string into an unsigned int * @param ptr A pointer to the string to convert -- cgit v1.2.3