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
aecb6406
Commit
aecb6406
authored
Nov 07, 2013
by
antirez
Browse files
Fix broken rdbWriteRaw() return value check in rdb.c.
Thanks to @PhoneLi for reporting.
parent
55b6c415
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/rdb.c
View file @
aecb6406
...
...
@@ -99,7 +99,7 @@ int rdbSaveLen(rio *rdb, uint32_t len) {
buf
[
0
]
=
(
REDIS_RDB_32BITLEN
<<
6
);
if
(
rdbWriteRaw
(
rdb
,
buf
,
1
)
==
-
1
)
return
-
1
;
len
=
htonl
(
len
);
if
(
rdbWriteRaw
(
rdb
,
&
len
,
4
)
==
-
4
)
return
-
1
;
if
(
rdbWriteRaw
(
rdb
,
&
len
,
4
)
==
-
1
)
return
-
1
;
nwritten
=
1
+
4
;
}
return
nwritten
;
...
...
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