{"thread":{"id":"42599","subject":"[PATCH v2] strbuf: describe the return value of strbuf_read_file","startedAt":"2016-06-16T06:55:52Z","lastAt":"2016-06-16T06:55:52Z","messageCount":1,"participants":["Pranit Bauva"],"isPatch":true,"patchVersion":2,"patchTotal":null},"messages":[{"id":"289187","messageId":"20160614061411.4061-1-pranit.bauva@gmail.com","threadId":"42599","inReplyTo":null,"subject":"[PATCH v2] strbuf: describe the return value of strbuf_read_file","fromName":"Pranit Bauva","fromEmail":"pranit.bauva@gmail.com","sentAt":"2016-06-14T06:14:11Z","receivedAt":"2016-06-16T06:55:52Z","isPatch":true,"sender":{"key":"pranit.bauva@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2959938?v=4"},"body":"Mentored-by: Lars Schneider <larsxschneider@gmail.com>\nMentored-by: Christian Couder <chriscool@tuxfamily.org>\nSigned-off-by: Pranit Bauva <pranit.bauva@gmail.com>\n---\n strbuf.h | 2 ++\n 1 file changed, 2 insertions(+)\n\ndiff --git a/strbuf.h b/strbuf.h\nindex 7987405..83c5c98 100644\n--- a/strbuf.h\n+++ b/strbuf.h\n@@ -377,6 +377,8 @@ extern ssize_t strbuf_read_once(struct strbuf *, int fd, size_t hint);\n /**\n  * Read the contents of a file, specified by its path. The third argument\n  * can be used to give a hint about the file size, to avoid reallocs.\n+ * Return the number of bytes read or a negative value if some error\n+ * occurred while opening or reading the file.\n  */\n extern ssize_t strbuf_read_file(struct strbuf *sb, const char *path, size_t hint);\n \n-- \n2.8.4\n"}]}