Commit 9a6992c4 by Edward Thomson

merge: safely cast size of merged file for index

Explicitly truncate the file size to a `uint32_t`.
parent b205f538
...@@ -867,7 +867,7 @@ static int merge_conflict_invoke_driver( ...@@ -867,7 +867,7 @@ static int merge_conflict_invoke_driver(
git_oid_cpy(&result->id, &oid); git_oid_cpy(&result->id, &oid);
result->mode = mode; result->mode = mode;
result->file_size = buf.size; result->file_size = (uint32_t)buf.size;
result->path = git_pool_strdup(&diff_list->pool, path); result->path = git_pool_strdup(&diff_list->pool, path);
GIT_ERROR_CHECK_ALLOC(result->path); GIT_ERROR_CHECK_ALLOC(result->path);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment