From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from metis.ext.pengutronix.de ([2001:6f8:1178:4:290:27ff:fe1d:cc33]) by bombadil.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1Rb8ae-0004E6-Rr for barebox@lists.infradead.org; Thu, 15 Dec 2011 10:31:10 +0000 From: Sascha Hauer Date: Thu, 15 Dec 2011 11:30:25 +0100 Message-Id: <1323945034-19687-4-git-send-email-s.hauer@pengutronix.de> In-Reply-To: <1323945034-19687-1-git-send-email-s.hauer@pengutronix.de> References: <1323945034-19687-1-git-send-email-s.hauer@pengutronix.de> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: barebox-bounces@lists.infradead.org Errors-To: barebox-bounces+u.kleine-koenig=pengutronix.de@lists.infradead.org Subject: [PATCH 03/12] uncompress: implement uncompress_fd_to_buf To: barebox@lists.infradead.org Signed-off-by: Sascha Hauer --- lib/uncompress.c | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/lib/uncompress.c b/lib/uncompress.c index beb96d1..cdfebe9 100644 --- a/lib/uncompress.c +++ b/lib/uncompress.c @@ -158,3 +158,11 @@ int uncompress_fd_to_fd(int infd, int outfd, NULL, error_fn); } + +int uncompress_fd_to_buf(int infd, void *output, + void(*error_fn)(char *x)) +{ + uncompress_infd = infd; + + return uncompress(NULL, 0, fill_fd, NULL, output, NULL, error_fn); +} -- 1.7.7.3 _______________________________________________ barebox mailing list barebox@lists.infradead.org http://lists.infradead.org/mailman/listinfo/barebox