Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
29e488cb
Commit
29e488cb
authored
Oct 16, 2018
by
Damien Tournoud
Browse files
Overhead is the allocated size of the AOF buffer, not its length
parent
f54cde3a
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/evict.c
View file @
29e488cb
...
@@ -364,7 +364,7 @@ size_t freeMemoryGetNotCountedMemory(void) {
...
@@ -364,7 +364,7 @@ size_t freeMemoryGetNotCountedMemory(void) {
}
}
}
}
if
(
server
.
aof_state
!=
AOF_OFF
)
{
if
(
server
.
aof_state
!=
AOF_OFF
)
{
overhead
+=
sds
len
(
server
.
aof_buf
)
+
aofRewriteBufferSize
();
overhead
+=
sds
alloc
(
server
.
aof_buf
)
+
aofRewriteBufferSize
();
}
}
return
overhead
;
return
overhead
;
}
}
...
...
src/object.c
View file @
29e488cb
...
@@ -1011,7 +1011,7 @@ struct redisMemOverhead *getMemoryOverheadData(void) {
...
@@ -1011,7 +1011,7 @@ struct redisMemOverhead *getMemoryOverheadData(void) {
mem
=
0
;
mem
=
0
;
if
(
server
.
aof_state
!=
AOF_OFF
)
{
if
(
server
.
aof_state
!=
AOF_OFF
)
{
mem
+=
sds
len
(
server
.
aof_buf
);
mem
+=
sds
alloc
(
server
.
aof_buf
);
mem
+=
aofRewriteBufferSize
();
mem
+=
aofRewriteBufferSize
();
}
}
mh
->
aof_buffer
=
mem
;
mh
->
aof_buffer
=
mem
;
...
...
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