commit: --amend -m '' silently fails to wipe message
[gitweb.git] / strbuf.c
index 88cafd4a70b8179a4e911c18704fb4ab0f2a21f5..b4da9f5d05fc1f22f8910a21d8e352f2e5e9673f 100644 (file)
--- a/strbuf.c
+++ b/strbuf.c
@@ -481,9 +481,10 @@ int strbuf_getwholeline_fd(struct strbuf *sb, int fd, int term)
        return 0;
 }
 
-int strbuf_read_file(struct strbuf *sb, const char *path, size_t hint)
+ssize_t strbuf_read_file(struct strbuf *sb, const char *path, size_t hint)
 {
-       int fd, len;
+       int fd;
+       ssize_t len;
 
        fd = open(path, O_RDONLY);
        if (fd < 0)