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
mpim-sw
libcdi
Commits
2a7a80fa
Commit
2a7a80fa
authored
Dec 08, 2014
by
Thomas Jahns
🤸
Browse files
Extract single-pass part from loop.
parent
52de3ed3
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/resource_unpack.c
View file @
2a7a80fa
...
...
@@ -28,19 +28,22 @@ void reshUnpackResources(char * unpackBuffer, int unpackBufferSize,
=
(
struct
streamAssoc
*
)
xmalloc
(
sizeof
(
associations
[
0
])
*
(
size_t
)
sizeAssociations
);
{
int
msgHdr
[
2
];
serializeUnpack
(
unpackBuffer
,
unpackBufferSize
,
&
unpackBufferPos
,
&
msgHdr
,
2
,
DATATYPE_INT
,
context
);
if
(
msgHdr
[
0
]
!=
START
)
xabort
(
"error parsing resource serialization buffer"
);
originNamespace
=
msgHdr
[
1
];
}
while
(
unpackBufferPos
<
unpackBufferSize
)
{
serializeUnpack
(
unpackBuffer
,
unpackBufferSize
,
&
unpackBufferPos
,
&
token1
,
1
,
DATATYPE_INT
,
context
);
if
(
token1
==
END
)
break
;
switch
(
token1
)
{
case
START
:
serializeUnpack
(
unpackBuffer
,
unpackBufferSize
,
&
unpackBufferPos
,
&
originNamespace
,
1
,
DATATYPE_INT
,
context
);
break
;
case
GRID
:
gridUnpack
(
unpackBuffer
,
unpackBufferSize
,
&
unpackBufferPos
,
originNamespace
,
context
,
1
);
...
...
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