From 38d6569e36163dabac8f921f97a7e4d5f0aa6572 Mon Sep 17 00:00:00 2001 From: Shahram Najm Date: Fri, 27 Oct 2023 17:58:34 +0100 Subject: [PATCH] Cleanup --- src/grib_accessor_class_data_g22order_packing.cc | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/grib_accessor_class_data_g22order_packing.cc b/src/grib_accessor_class_data_g22order_packing.cc index af462d667..f45d9f722 100644 --- a/src/grib_accessor_class_data_g22order_packing.cc +++ b/src/grib_accessor_class_data_g22order_packing.cc @@ -267,11 +267,9 @@ static void add_bitstream(bitstream_context *ctx, grib_accessor* a, int t, int n return; } -/* - * find min/max of an integer array - * return 0: if min max found - * return 1: if min max not found, min = max = 0 - */ +// find min/max of an integer array +// return 0: if min max found +// return 1: if min max not found, min = max = 0 static int int_min_max_array(int* data, unsigned int n, int* min, int* max) { unsigned int first; @@ -1325,8 +1323,8 @@ static int pack_double(grib_accessor* a, const double* val, size_t* len) grib_context_log(a->context, GRIB_LOG_ERROR, "%s packing: failed to get min max of data", cclass_name); return GRIB_ENCODING_ERROR; } - min_val = static_cast(mn); - max_val = static_cast(mx); + min_val = mn; + max_val = mx; binary_scale = bin_scale;