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
3343b5ff
Commit
3343b5ff
authored
Oct 31, 2013
by
Linquize
Committed by
Vicent Marti
Nov 01, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix warning on win64
parent
ab44c62e
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
6 deletions
+7
-6
src/indexer.c
+3
-2
src/pack-objects.c
+2
-2
src/pack.c
+1
-1
src/pack.h
+1
-1
No files found.
src/indexer.c
View file @
3343b5ff
...
...
@@ -632,7 +632,8 @@ static int inject_object(git_indexer_stream *idx, git_oid *id)
git_buf
buf
=
GIT_BUF_INIT
;
git_off_t
entry_start
;
const
void
*
data
;
size_t
len
,
hdr_len
;
size_t
len
;
int
hdr_len
;
int
error
;
entry
=
git__calloc
(
1
,
sizeof
(
*
entry
));
...
...
@@ -660,7 +661,7 @@ static int inject_object(git_indexer_stream *idx, git_oid *id)
/* And then the compressed object */
git_filebuf_write
(
&
idx
->
pack_file
,
buf
.
ptr
,
buf
.
size
);
idx
->
pack
->
mwf
.
size
+=
buf
.
size
;
entry
->
crc
=
htonl
(
crc32
(
entry
->
crc
,
(
unsigned
char
*
)
buf
.
ptr
,
buf
.
size
));
entry
->
crc
=
htonl
(
crc32
(
entry
->
crc
,
(
unsigned
char
*
)
buf
.
ptr
,
(
uInt
)
buf
.
size
));
git_buf_free
(
&
buf
);
/* Write a fake trailer so the pack functions play ball */
...
...
src/pack-objects.c
View file @
3343b5ff
...
...
@@ -26,7 +26,7 @@ struct unpacked {
git_pobject
*
object
;
void
*
data
;
struct
git_delta_index
*
index
;
unsigned
int
depth
;
int
depth
;
};
struct
tree_walk_context
{
...
...
@@ -659,7 +659,7 @@ static int delta_cacheable(git_packbuilder *pb, unsigned long src_size,
}
static
int
try_delta
(
git_packbuilder
*
pb
,
struct
unpacked
*
trg
,
struct
unpacked
*
src
,
unsigned
int
max_depth
,
struct
unpacked
*
src
,
int
max_depth
,
unsigned
long
*
mem_usage
,
int
*
ret
)
{
git_pobject
*
trg_object
=
trg
->
object
;
...
...
src/pack.c
View file @
3343b5ff
...
...
@@ -372,7 +372,7 @@ static unsigned char *pack_window_open(
* - each byte afterwards: low seven bits are size continuation,
* with the high bit being "size continues"
*/
int
git_packfile__object_header
(
unsigned
char
*
hdr
,
unsigned
long
size
,
git_otype
type
)
int
git_packfile__object_header
(
unsigned
char
*
hdr
,
size_t
size
,
git_otype
type
)
{
unsigned
char
*
hdr_base
;
unsigned
char
c
;
...
...
src/pack.h
View file @
3343b5ff
...
...
@@ -112,7 +112,7 @@ typedef struct git_packfile_stream {
git_mwindow
*
mw
;
}
git_packfile_stream
;
int
git_packfile__object_header
(
unsigned
char
*
hdr
,
unsigned
long
size
,
git_otype
type
);
int
git_packfile__object_header
(
unsigned
char
*
hdr
,
size_t
size
,
git_otype
type
);
int
git_packfile_unpack_header
(
size_t
*
size_p
,
...
...
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