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
aee1ddca
Commit
aee1ddca
authored
Jan 26, 2017
by
miter
Committed by
antirez
Jan 30, 2017
Browse files
Change switch statment to if statment
parent
af292b54
Changes
1
Show whitespace changes
Inline
Side-by-side
src/object.c
View file @
aee1ddca
...
@@ -246,11 +246,9 @@ void freeStringObject(robj *o) {
...
@@ -246,11 +246,9 @@ void freeStringObject(robj *o) {
}
}
void
freeListObject
(
robj
*
o
)
{
void
freeListObject
(
robj
*
o
)
{
switch
(
o
->
encoding
)
{
if
(
o
->
encoding
==
OBJ_ENCODING_QUICKLIST
)
{
case
OBJ_ENCODING_QUICKLIST
:
quicklistRelease
(
o
->
ptr
);
quicklistRelease
(
o
->
ptr
);
break
;
}
else
{
default:
serverPanic
(
"Unknown list encoding type"
);
serverPanic
(
"Unknown list encoding type"
);
}
}
}
}
...
...
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