Commit 2cb27cf8 authored by Uwe Schulzweida's avatar Uwe Schulzweida
Browse files

read_remap_scrip: abort if no remap weights are available

parent 271b177e
......@@ -600,6 +600,9 @@ void read_remap_scrip(const char *interp_file, int gridID1, int gridID2, int *ma
nce(nc_inq_dimlen(nc_file_id, nc_numlinks_id, &dimlen));
rv->num_links = dimlen;
if ( rv->num_links == 0 )
cdoAbort("Number of remap links is 0, no remap weights found!");
nce(nc_inq_dimid(nc_file_id, "num_wgts", &nc_numwgts_id));
nce(nc_inq_dimlen(nc_file_id, nc_numwgts_id, &dimlen));
rv->num_wts = dimlen;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment