Skip to content

Commit f792731

Browse files
committed
Merge branch 'pb/strbuf-read-file-doc' into maint
Minor doc update. * pb/strbuf-read-file-doc: strbuf: describe the return value of strbuf_read_file
2 parents 1c22105 + ed008d7 commit f792731

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

strbuf.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -377,6 +377,8 @@ extern ssize_t strbuf_read_once(struct strbuf *, int fd, size_t hint);
377377
/**
378378
* Read the contents of a file, specified by its path. The third argument
379379
* can be used to give a hint about the file size, to avoid reallocs.
380+
* Return the number of bytes read or a negative value if some error
381+
* occurred while opening or reading the file.
380382
*/
381383
extern ssize_t strbuf_read_file(struct strbuf *sb, const char *path, size_t hint);
382384

0 commit comments

Comments
 (0)