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
e86e81c5
Commit
e86e81c5
authored
Feb 12, 2022
by
Edward Thomson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
oid: make empty tree id global
Move the empty tree ID into a global space so that it can be generally used.
parent
e1415dc3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
0 deletions
+6
-0
src/oid.c
+4
-0
src/oid.h
+2
-0
No files found.
src/oid.c
View file @
e86e81c5
...
...
@@ -13,6 +13,10 @@
#include <string.h>
#include <limits.h>
const
git_oid
git_oid__empty_tree_sha1
=
{{
0x4b
,
0x82
,
0x5d
,
0xc6
,
0x42
,
0xcb
,
0x6e
,
0xb9
,
0xa0
,
0x60
,
0xe5
,
0x4b
,
0xf8
,
0xd6
,
0x92
,
0x88
,
0xfb
,
0xee
,
0x49
,
0x04
}};
static
char
to_hex
[]
=
"0123456789abcdef"
;
static
int
oid_error_invalid
(
const
char
*
msg
)
...
...
src/oid.h
View file @
e86e81c5
...
...
@@ -11,6 +11,8 @@
#include "git2/oid.h"
extern
const
git_oid
git_oid__empty_tree_sha1
;
/**
* Format a git_oid into a newly allocated c-string.
*
...
...
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