From e4d974bb63355d1fff92eaae4df5f0cdf3597dc3 Mon Sep 17 00:00:00 2001 From: Artem Bityutskiy Date: Wed, 22 Apr 2009 14:32:08 +0300 Subject: libubi: improve libubi_open interface Remove the not very nice @required parameter, and add a possibility to distinguish between real errors and a situation when UBI is not present. Signed-off-by: Artem Bityutskiy --- ubi-utils/include/libubi.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'ubi-utils/include') diff --git a/ubi-utils/include/libubi.h b/ubi-utils/include/libubi.h index 71a78a3..bc3404c 100644 --- a/ubi-utils/include/libubi.h +++ b/ubi-utils/include/libubi.h @@ -170,13 +170,13 @@ struct ubi_vol_info /** * libubi_open - open UBI library. - * @required: if non-zero, libubi will print an error messages if this UBI is - * not present in the system * * This function initializes and opens the UBI library and returns UBI library - * descriptor in case of success and %NULL in case of failure. + * descriptor in case of success and %NULL in case of failure. In case of + * failure, errno contains the error code or zero if UBI is not present in the + * system. */ -libubi_t libubi_open(int required); +libubi_t libubi_open(void); /** * libubi_close - close UBI library. -- cgit v1.2.3