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
bf5792bf
Commit
bf5792bf
authored
Dec 07, 2015
by
Thomas Jahns
🤸
Browse files
Switch SRV grid template to dynamic memory.
parent
cb3817de
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/stream_srv.c
View file @
bf5792bf
...
...
@@ -209,15 +209,16 @@ void srv_add_record(stream_t *streamptr, int param, int level, int xsize, int ys
record
->
param
=
param
;
record
->
ilevel
=
level
;
grid_t
grid
;
grid_init
(
&
grid
);
grid
.
type
=
GRID_GENERIC
;
grid
.
size
=
xsize
*
ysize
;
grid
.
xsize
=
xsize
;
grid
.
ysize
=
ysize
;
grid
.
xvals
=
NULL
;
grid
.
yvals
=
NULL
;
int
gridID
=
varDefGrid
(
vlistID
,
&
grid
,
0
);
grid_t
*
grid
=
(
grid_t
*
)
Malloc
(
sizeof
(
*
grid
));
grid_init
(
grid
);
grid
->
type
=
GRID_GENERIC
;
grid
->
size
=
xsize
*
ysize
;
grid
->
xsize
=
xsize
;
grid
->
ysize
=
ysize
;
grid
->
xvals
=
NULL
;
grid
->
yvals
=
NULL
;
int
gridID
=
varDefGrid
(
vlistID
,
grid
,
0
);
Free
(
grid
);
/*
if ( level == 0 ) leveltype = ZAXIS_SURFACE;
else leveltype = ZAXIS_GENERIC;
...
...
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