From 7d3e17b86b8837de068daa7ed96604e93c8edcb2 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Sat, 22 Jan 2011 14:37:07 +0100 Subject: [PATCH] Document xbps_humanize_number() in the API. --HG-- branch : progress_callback --- include/xbps_api.h | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/include/xbps_api.h b/include/xbps_api.h index 2a02cd15..7348b9ed 100644 --- a/include/xbps_api.h +++ b/include/xbps_api.h @@ -294,7 +294,6 @@ const char *xbps_fetch_error_string(void); /*@}*/ -int xbps_humanize_number(char *, int64_t); /** * @ingroup pkg_orphans @@ -1210,6 +1209,18 @@ void xbps_set_cachedir(const char *cachedir); */ const char *xbps_get_cachedir(void); +/** + * Converts the 64 bits signed number specified in \a bytes to + * a human parsable string buffer pointed to \a buf. + * + * @param[out] buf Buffer to store the resulting string. At least + * it should have space for 6 chars. + * @param[in] bytes 64 bits signed number to convert. + * + * @return A negative number is returned on error, 0 otherwise. + */ +int xbps_humanize_number(char *buf, int64_t bytes); + /** * Sets the flag specified in \a flags for internal use. *