Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
B
brpc
Project
Project
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
brpc
Commits
6a8aaeec
Commit
6a8aaeec
authored
Jan 07, 2020
by
zhujiashun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
replace_crc32_ts: update
parent
becf705b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
ts.cpp
src/brpc/ts.cpp
+3
-3
No files found.
src/brpc/ts.cpp
View file @
6a8aaeec
...
...
@@ -123,9 +123,9 @@ static const uint32_t crctab[] = {
uint32_t
crc32_ts
(
const
void
*
data
,
size_t
len
)
{
const
uint8_t
*
p
=
(
const
uint8_t
*
)
data
;
uint32_t
crc
=
-
1
;
for
(
size_t
i
=
0
;
i
<
len
;
++
i
,
p
++
)
{
crc
=
(
crc
<<
8
)
^
crctab
[(
crc
>>
24
)
^
*
p
];
uint32_t
crc
=
0xffffffff
;
for
(
size_t
i
=
0
;
i
<
len
;
++
i
)
{
crc
=
(
crc
<<
8
)
^
crctab
[(
crc
>>
24
)
^
*
p
++
];
}
return
crc
;
}
...
...
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