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
hiredis
Commits
33a36dc2
Commit
33a36dc2
authored
May 20, 2018
by
michael-grunder
Browse files
Don't overflow 32 bit machines in the tests!
parent
60f622b8
Changes
1
Show whitespace changes
Inline
Side-by-side
test.c
View file @
33a36dc2
...
...
@@ -695,7 +695,7 @@ static void test_throughput(struct config config) {
replies
=
malloc
(
sizeof
(
redisReply
*
)
*
num
);
t1
=
usec
();
for
(
i
=
0
;
i
<
num
;
i
++
)
{
replies
[
i
]
=
redisCommand
(
c
,
"INCRBY incrkey %
ll
d"
,
1000000
0
);
replies
[
i
]
=
redisCommand
(
c
,
"INCRBY incrkey %d"
,
1000000
);
assert
(
replies
[
i
]
!=
NULL
&&
replies
[
i
]
->
type
==
REDIS_REPLY_INTEGER
);
}
t2
=
usec
();
...
...
@@ -733,7 +733,7 @@ static void test_throughput(struct config config) {
replies
=
malloc
(
sizeof
(
redisReply
*
)
*
num
);
for
(
i
=
0
;
i
<
num
;
i
++
)
redisAppendCommand
(
c
,
"INCRBY incrkey %
ll
d"
,
1000000
0
);
redisAppendCommand
(
c
,
"INCRBY incrkey %d"
,
1000000
);
t1
=
usec
();
for
(
i
=
0
;
i
<
num
;
i
++
)
{
assert
(
redisGetReply
(
c
,
(
void
*
)
&
replies
[
i
])
==
REDIS_OK
);
...
...
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