Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mpim-sw
libcdi
Commits
215c5117
Commit
215c5117
authored
Oct 28, 2015
by
Thomas Jahns
🤸
Browse files
Narrow scope of variable.
parent
03e4ed68
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/vlist.c
View file @
215c5117
...
...
@@ -730,12 +730,12 @@ void vlistCat(int vlistID2, int vlistID1)
var_copy_entries
(
&
vars2
[
varID2
],
&
vars1
[
varID
]);
int
nlevs
=
zaxisInqSize
(
vars1
[
varID
].
zaxisID
);
if
(
vars1
[
varID
].
levinfo
)
{
vars2
[
varID2
].
levinfo
=
(
levinfo_t
*
)
Malloc
((
size_t
)
nlevs
*
sizeof
(
levinfo_t
));
size_t
nlevs
=
(
size_t
)
zaxisInqSize
(
vars1
[
varID
].
zaxisID
);
vars2
[
varID2
].
levinfo
=
(
levinfo_t
*
)
Malloc
(
nlevs
*
sizeof
(
levinfo_t
));
memcpy
(
vars2
[
varID2
].
levinfo
,
vars1
[
varID
].
levinfo
,
(
size_t
)
nlevs
*
sizeof
(
levinfo_t
));
nlevs
*
sizeof
(
levinfo_t
));
}
vars2
[
varID2
].
atts
.
nelems
=
0
;
...
...
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