From 8fdcfdb4479dff7a993a25a63253f0e749fd99fe Mon Sep 17 00:00:00 2001 From: Rob Landley Date: Tue, 3 Sep 2013 17:56:28 -0500 Subject: Introduce libbuf analogous to toybuf but for use by lib/*.c. Change readfile() semantics to be able to read into an existing buffer, or malloc its own if that's NULL. --- lib/xwrap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/xwrap.c') diff --git a/lib/xwrap.c b/lib/xwrap.c index 2b0690f3..90c4d86a 100644 --- a/lib/xwrap.c +++ b/lib/xwrap.c @@ -425,7 +425,7 @@ char *xreadlink(char *name) char *xreadfile(char *name) { - char *buf = readfile(name); + char *buf = readfile(name, 0, 0); if (!buf) perror_exit("xreadfile %s", name); return buf; } -- cgit v1.2.3