mirror of https://github.com/ecmwf/eccodes.git
Examples: print error rather than assert
This commit is contained in:
parent
d1ae16ae15
commit
9e52edd4a3
|
@ -62,8 +62,10 @@ int main(int argc, char* argv[])
|
|||
}
|
||||
|
||||
is_missing = codes_is_missing(h, "relativeHumidity", &err);
|
||||
assert(!err);
|
||||
assert(is_missing == 1);
|
||||
if (err || !is_missing) {
|
||||
fprintf(stderr, "Error: relativeHumidity should be 'missing'\n");
|
||||
return 1;
|
||||
}
|
||||
|
||||
/* Set some other keys to be missing */
|
||||
CODES_CHECK(codes_set_missing(h, "blockNumber"), 0);
|
||||
|
|
Loading…
Reference in New Issue