Skip to content

Commit 8561b52

Browse files
committed
Merge branch 'maint-1.6.0' into maint
* maint-1.6.0: avoid 31-bit truncation in write_loose_object
2 parents 02322e1 + 915308b commit 8561b52

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

sha1_file.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2337,7 +2337,8 @@ static int create_tmpfile(char *buffer, size_t bufsiz, const char *filename)
23372337
static int write_loose_object(const unsigned char *sha1, char *hdr, int hdrlen,
23382338
void *buf, unsigned long len, time_t mtime)
23392339
{
2340-
int fd, size, ret;
2340+
int fd, ret;
2341+
size_t size;
23412342
unsigned char *compressed;
23422343
z_stream stream;
23432344
char *filename;

0 commit comments

Comments
 (0)