Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
sds
ssg
Commits
af1b4875
Commit
af1b4875
authored
Apr 24, 2017
by
Shane Snyder
Browse files
dumb bug fix for swim segfaults
parent
af109680
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/swim-fd/swim-fd-ping.c
View file @
af1b4875
...
...
@@ -17,6 +17,12 @@
#include
"swim-fd.h"
#include
"swim-fd-internal.h"
/* NOTE these defines must be kept in sync with typedefs in
* swim-internal.h
*/
#define hg_proc_swim_member_id_t hg_proc_int64_t
#define hg_proc_swim_member_status_t hg_proc_uint8_t
#define hg_proc_swim_member_inc_nr_t hg_proc_uint32_t
MERCURY_GEN_STRUCT_PROC
(
swim_member_update_t
,
\
((
swim_member_id_t
)
(
id
))
\
...
...
@@ -386,13 +392,13 @@ static hg_return_t hg_proc_swim_message_t(hg_proc_t proc, void *data)
switch
(
hg_proc_get_op
(
proc
))
{
case
HG_ENCODE
:
hret
=
hg_proc_
int32
_t
(
proc
,
&
(
msg
->
source_id
));
hret
=
hg_proc_
swim_member_id
_t
(
proc
,
&
(
msg
->
source_id
));
if
(
hret
!=
HG_SUCCESS
)
{
hret
=
HG_PROTOCOL_ERROR
;
return
hret
;
}
hret
=
hg_proc_
uint32
_t
(
proc
,
&
(
msg
->
source_inc_nr
));
hret
=
hg_proc_
swim_member_inc_nr
_t
(
proc
,
&
(
msg
->
source_inc_nr
));
if
(
hret
!=
HG_SUCCESS
)
{
hret
=
HG_PROTOCOL_ERROR
;
...
...
@@ -409,13 +415,13 @@ static hg_return_t hg_proc_swim_message_t(hg_proc_t proc, void *data)
}
break
;
case
HG_DECODE
:
hret
=
hg_proc_
int32
_t
(
proc
,
&
(
msg
->
source_id
));
hret
=
hg_proc_
swim_member_id
_t
(
proc
,
&
(
msg
->
source_id
));
if
(
hret
!=
HG_SUCCESS
)
{
hret
=
HG_PROTOCOL_ERROR
;
return
hret
;
}
hret
=
hg_proc_
uint32
_t
(
proc
,
&
(
msg
->
source_inc_nr
));
hret
=
hg_proc_
swim_member_inc_nr
_t
(
proc
,
&
(
msg
->
source_inc_nr
));
if
(
hret
!=
HG_SUCCESS
)
{
hret
=
HG_PROTOCOL_ERROR
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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