mirror of https://github.com/ecmwf/eccodes.git
ECC-1253: GRIB2: Error when setting localDefinitionNumber (centre=98)
This commit is contained in:
parent
cabb2d54bb
commit
02b25b085f
|
@ -333,8 +333,14 @@ static int pack_long(grib_accessor* a, const long* val, size_t* len)
|
|||
break;
|
||||
|
||||
default:
|
||||
grib_context_log(a->context, GRIB_LOG_ERROR, "Invalid localDefinitionNumber %d", localDefinitionNumber);
|
||||
#ifdef DEBUG
|
||||
/* In test & development mode, fail so we remember to adjust PDTN */
|
||||
grib_context_log(a->context, GRIB_LOG_ERROR,
|
||||
"grib_accessor_local_definition: Invalid localDefinitionNumber %d", localDefinitionNumber);
|
||||
return GRIB_ENCODING_ERROR;
|
||||
#endif
|
||||
/* ECC-1253: Do not fail in operations. Leave PDTN as is */
|
||||
productDefinitionTemplateNumberNew = productDefinitionTemplateNumber;
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue