ECC-1673: MARS: add mars.number to the combination ocda/tpa

This commit is contained in:
Shahram Najm 2023-08-29 14:03:22 +01:00
parent 3932f86df3
commit cf50f62e0a
2 changed files with 4 additions and 1 deletions

View File

@ -6,3 +6,6 @@ alias mars.time = dataTime;
unalias mars.step; unalias mars.step;
alias mars.step = stepRange; alias mars.step = stepRange;
if (defined(perturbationNumber)) {
alias mars.number = perturbationNumber;
}

View File

@ -342,7 +342,7 @@ static void dump_values(grib_dumper* d, grib_accessor* a)
fprintf(self->dumper.out, " size = %zu;\n", size); fprintf(self->dumper.out, " size = %zu;\n", size);
fprintf(self->dumper.out, " v%s = (%s*)calloc(size,sizeof(%s));\n", stype, stype, stype); fprintf(self->dumper.out, " v%s = (%s*)calloc(size,sizeof(%s));\n", stype, stype, stype);
fprintf(self->dumper.out, " if(!v%s) {\n", stype); fprintf(self->dumper.out, " if(!v%s) {\n", stype);
fprintf(self->dumper.out, " fprintf(stderr,\"failed to allocate %%d bytes\\n\",size*sizeof(%s));\n", stype); fprintf(self->dumper.out, " fprintf(stderr,\"failed to allocate %%zu bytes\\n\",size*sizeof(%s));\n", stype);
fprintf(self->dumper.out, " exit(1);\n"); fprintf(self->dumper.out, " exit(1);\n");
fprintf(self->dumper.out, " }\n"); fprintf(self->dumper.out, " }\n");