Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
git2
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
git2
Commits
a0acf60e
Commit
a0acf60e
authored
Mar 03, 2021
by
panda
Committed by
Edward Thomson
Jun 30, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
merge: Check insert_head_ids error in create_virtual_base
insert_head_ids can fail due to allocation error
parent
c0358ee1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
2 deletions
+5
-2
src/merge.c
+5
-2
No files found.
src/merge.c
View file @
a0acf60e
...
...
@@ -2258,8 +2258,11 @@ static int create_virtual_base(
result
->
type
=
GIT_ANNOTATED_COMMIT_VIRTUAL
;
result
->
index
=
index
;
insert_head_ids
(
&
result
->
parents
,
one
);
insert_head_ids
(
&
result
->
parents
,
two
);
if
(
insert_head_ids
(
&
result
->
parents
,
one
)
<
0
||
insert_head_ids
(
&
result
->
parents
,
two
)
<
0
)
{
git_annotated_commit_free
(
result
);
return
-
1
;
}
*
out
=
result
;
return
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment