os_readfile() function
os_readfile - Read a file to an allocated memory buffer @name: Name of the file to read @len: For returning the length of the allocated buffer Returns: Pointer to the allocated buffer or %NULL on failure This function allocates memory and reads the given file to this buffer. Both binary and text files can be read with this function. The caller is responsible for freeing the returned buffer with os_free().
Syntax
static inline char *os_readfile(const char *name,
size_t *len);