mirror of https://github.com/ecmwf/eccodes.git
Testing: smart_table unpack_string
This commit is contained in:
parent
f5c4761861
commit
18edad5b52
|
@ -545,7 +545,7 @@ static int unpack_long(grib_accessor* a, long* val, size_t* len)
|
||||||
|
|
||||||
if (*len < self->tableCodesSize) {
|
if (*len < self->tableCodesSize) {
|
||||||
grib_context_log(a->context, GRIB_LOG_ERROR,
|
grib_context_log(a->context, GRIB_LOG_ERROR,
|
||||||
"Wrong size (%lu) for %s it contains %lu values", *len, a->name, self->tableCodesSize);
|
"Wrong size (%zu) for %s, it contains %zu values", *len, a->name, self->tableCodesSize);
|
||||||
*len = 0;
|
*len = 0;
|
||||||
return GRIB_ARRAY_TOO_SMALL;
|
return GRIB_ARRAY_TOO_SMALL;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1290,6 +1290,15 @@ cat > $fRules <<EOF
|
||||||
EOF
|
EOF
|
||||||
${tools_dir}/codes_bufr_filter $fRules $f > $fLog
|
${tools_dir}/codes_bufr_filter $fRules $f > $fLog
|
||||||
|
|
||||||
|
# smart table unpack_string
|
||||||
|
tempBufr=temp.$label.bufr
|
||||||
|
f="$ECCODES_SAMPLES_PATH/BUFR4.tmpl"
|
||||||
|
cat > $fRules <<EOF
|
||||||
|
set unexpandedDescriptors = { 1031 };
|
||||||
|
print "[expandedOriginalCodes:s]";
|
||||||
|
EOF
|
||||||
|
${tools_dir}/codes_bufr_filter -o $tempBufr $fRules $f
|
||||||
|
rm -f $tempBufr
|
||||||
|
|
||||||
# Clean up
|
# Clean up
|
||||||
rm -f ${f}.log ${f}.log.ref ${f}.out $fLog $fRules
|
rm -f ${f}.log ${f}.log.ref ${f}.out $fLog $fRules
|
||||||
|
|
Loading…
Reference in New Issue