Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
opendht
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
opendht
Commits
84578f78
Commit
84578f78
authored
8 years ago
by
Adrien Béraud
Browse files
Options
Downloads
Patches
Plain Diff
value: reduce size limit to 14KB
parent
14cf0b31
Loading
Loading
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
include/opendht/dht.h
+1
-1
1 addition, 1 deletion
include/opendht/dht.h
include/opendht/value.h
+1
-1
1 addition, 1 deletion
include/opendht/value.h
with
2 additions
and
2 deletions
include/opendht/dht.h
+
1
−
1
View file @
84578f78
...
...
@@ -266,7 +266,7 @@ private:
static
constexpr
unsigned
LISTEN_NODES
{
3
};
/* The maximum number of values we store for a given hash. */
static
constexpr
unsigned
MAX_VALUES
{
2048
};
static
constexpr
unsigned
MAX_VALUES
{
1024
};
/* The maximum number of hashes we're willing to track. */
static
constexpr
unsigned
MAX_HASHES
{
16384
};
...
...
This diff is collapsed.
Click to expand it.
include/opendht/value.h
+
1
−
1
View file @
84578f78
...
...
@@ -80,7 +80,7 @@ using StorePolicy = std::function<bool(InfoHash key, std::shared_ptr<Value>& val
*/
using
EditPolicy
=
std
::
function
<
bool
(
InfoHash
key
,
const
std
::
shared_ptr
<
Value
>&
old_val
,
std
::
shared_ptr
<
Value
>&
new_val
,
InfoHash
from
,
const
sockaddr
*
from_addr
,
socklen_t
from_len
)
>
;
static
constexpr
const
size_t
MAX_VALUE_SIZE
{
1024
*
56
};
static
constexpr
const
size_t
MAX_VALUE_SIZE
{
1024
*
14
};
struct
ValueType
{
typedef
uint16_t
Id
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment