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
7bfba4d1
Commit
7bfba4d1
authored
Mar 29, 2017
by
Thomas Jahns
🤸
Browse files
Fix needless global.
parent
470473a8
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/stream_gribapi.c
View file @
7bfba4d1
...
...
@@ -51,9 +51,6 @@ typedef struct {
}
compvar2_t
;
int
scanModeIN
;
// global variable
static
int
gribapiGetZaxisType
(
long
editionNumber
,
int
grib_ltype
)
{
...
...
@@ -2722,7 +2719,9 @@ void verticallyFlipGridDefinitionWhenScanningModeChanged(grib_handle *gh, double
}
#ifdef HIRLAM_EXTENSIONS
void
convertDataScanningMode
(
int
scanModeOUT
,
double
*
data
,
int
gridsize
,
int
iDim
,
int
jDim
)
static
void
convertDataScanningMode
(
int
scanModeIN
,
int
scanModeOUT
,
double
*
data
,
int
gridsize
,
int
iDim
,
int
jDim
)
{
int
i
,
j
;
int
idxIN
,
idxOUT
;
...
...
@@ -2936,7 +2935,7 @@ void gribapiSetExtMode(grib_handle *gh, int gridID, long datasize, const double
gridtype
==
GRID_GAUSSIAN_REDUCED
||
gridtype
==
GRID_PROJECTION
||
gridtype
==
GRID_LCC
)
{
//scanModeIN = gribapiGetScanningMode(gh);
scanModeIN
=
gridInqScanningMode
(
gridID
);
// use global variable scanModeIN
int
scanModeIN
=
gridInqScanningMode
(
gridID
);
if
(
cdiDebugExt
>=
100
)
{
...
...
@@ -2955,7 +2954,7 @@ void gribapiSetExtMode(grib_handle *gh, int gridID, long datasize, const double
double
yinc
=
gridInqYinc
(
gridID
);
int
scanModeOUT
=
cdiGribDataScanningMode
.
value
;
convertDataScanningMode
(
scanModeOUT
,
(
double
*
)
data
,
datasize
,
iDim
,
jDim
);
convertDataScanningMode
(
scanModeIN
,
scanModeOUT
,
(
double
*
)
data
,
datasize
,
iDim
,
jDim
);
// This will overrule the old scanning mode of the given grid
if
(
cdiDebugExt
>=
10
)
Message
(
"Set GribDataScanningMode (%d) => (%d)"
,
scanModeIN
,
cdiGribDataScanningMode
.
value
);
gribapiSetScanningMode
(
gh
,
cdiGribDataScanningMode
.
value
);
...
...
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