diff --git a/src/grib_accessor_class_bufr_extract_subsets.c b/src/grib_accessor_class_bufr_extract_subsets.c index e32c138f6..fc0295366 100644 --- a/src/grib_accessor_class_bufr_extract_subsets.c +++ b/src/grib_accessor_class_bufr_extract_subsets.c @@ -172,7 +172,11 @@ static int pack_long(grib_accessor* a, const long* val, size_t *len) v[0]=1; err=grib_pack_long(self->packAccessor,v,&l); - if (err) return err; + if (err) { + if (err == GRIB_ENCODING_ERROR) + grib_context_log(a->context,GRIB_LOG_ERROR,"Could not extract subset(s).\n\tHint: Did you forget to set unpack=1?"); + return err; + } return err; }