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
041d8e2a
Commit
041d8e2a
authored
May 14, 2011
by
Pieter Noordhuis
Browse files
Fix up rdbWriteRaw to return number of bytes written
parent
7271198c
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/rdb.c
View file @
041d8e2a
...
@@ -9,9 +9,9 @@
...
@@ -9,9 +9,9 @@
#include "lzf.h"
/* LZF compression library */
#include "lzf.h"
/* LZF compression library */
static
int
rdbWriteRaw
(
rio
*
rdb
,
void
*
p
,
size_t
len
)
{
static
int
rdbWriteRaw
(
rio
*
rdb
,
void
*
p
,
size_t
len
)
{
if
(
rioWrite
(
rdb
,
p
,
len
)
==
0
)
if
(
rdb
&&
rioWrite
(
rdb
,
p
,
len
)
==
0
)
return
-
1
;
return
-
1
;
return
1
;
return
len
;
}
}
int
rdbSaveType
(
rio
*
rdb
,
unsigned
char
type
)
{
int
rdbSaveType
(
rio
*
rdb
,
unsigned
char
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