From 2a436e4d47aeb0a6bff063307846747d1abb2335 Mon Sep 17 00:00:00 2001 From: lottaviano Date: Mon, 6 Dec 2010 11:53:30 +0000 Subject: [PATCH] doc: Clarify kfile_read() behaviour. git-svn-id: https://src.develer.com/svnoss/bertos/trunk@4617 38d2e660-2303-0410-9eaa-f027e97ec537 --- bertos/io/kfile.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/bertos/io/kfile.h b/bertos/io/kfile.h index 040e04a8..9b0b07d0 100644 --- a/bertos/io/kfile.h +++ b/bertos/io/kfile.h @@ -223,6 +223,12 @@ int kfile_genericClose(struct KFile *fd); /** * Read \a size bytes from file \a fd into \a buf. * + * This function reads at most the number of requested bytes into the + * provided buffer. + * The value returned may be less than the requested bytes in case EOF is + * reached OR an error occurred. You need to check the error conditions + * using kfile_error() to understand which case happened. + * * \note This function will block if there are less than \a size bytes * to read. * -- 2.25.1