Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
L
libzmq
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
libzmq
Commits
7302b9b8
Unverified
Commit
7302b9b8
authored
Jan 02, 2019
by
Luca Boccassi
Committed by
GitHub
Jan 02, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3345 from ssbl/unused-import
Problem: unused import and inconsistent use of const
parents
fc36c7d2
cc686f15
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
5 deletions
+4
-5
radix_tree.cpp
src/radix_tree.cpp
+3
-4
radix_tree.hpp
src/radix_tree.hpp
+1
-1
No files found.
src/radix_tree.cpp
View file @
7302b9b8
...
...
@@ -33,7 +33,6 @@
#include "radix_tree.hpp"
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
node
::
node
(
unsigned
char
*
data
)
:
data_
(
data
)
...
...
@@ -81,7 +80,7 @@ unsigned char *node::prefix ()
return
data_
+
3
*
sizeof
(
uint32_t
);
}
void
node
::
set_prefix
(
unsigned
char
const
*
bytes
)
void
node
::
set_prefix
(
const
unsigned
char
*
bytes
)
{
memcpy
(
prefix
(),
bytes
,
prefix_length
());
}
...
...
@@ -91,7 +90,7 @@ unsigned char *node::first_bytes ()
return
prefix
()
+
prefix_length
();
}
void
node
::
set_first_bytes
(
unsigned
char
const
*
bytes
)
void
node
::
set_first_bytes
(
const
unsigned
char
*
bytes
)
{
memcpy
(
first_bytes
(),
bytes
,
edgecount
());
}
...
...
@@ -113,7 +112,7 @@ unsigned char *node::node_ptrs ()
return
prefix
()
+
prefix_length
()
+
edgecount
();
}
void
node
::
set_node_ptrs
(
unsigned
char
const
*
ptrs
)
void
node
::
set_node_ptrs
(
const
unsigned
char
*
ptrs
)
{
memcpy
(
node_ptrs
(),
ptrs
,
edgecount
()
*
sizeof
(
void
*
));
}
...
...
src/radix_tree.hpp
View file @
7302b9b8
...
...
@@ -83,7 +83,7 @@ struct node
inline
void
set_prefix
(
const
unsigned
char
*
prefix
);
inline
void
set_first_bytes
(
const
unsigned
char
*
bytes
);
inline
void
set_first_byte_at
(
size_t
i
,
unsigned
char
byte
);
inline
void
set_node_ptrs
(
unsigned
char
const
*
ptrs
);
inline
void
set_node_ptrs
(
const
unsigned
char
*
ptrs
);
inline
void
set_node_at
(
size_t
i
,
node
n
);
inline
void
set_edge_at
(
size_t
i
,
unsigned
char
byte
,
node
n
);
void
resize
(
size_t
prefix_length
,
size_t
edgecount
);
...
...
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