plotit.c, check for infinite y values

This commit is contained in:
h_vogt 2017-05-25 12:16:06 +02:00
parent 93e243993d
commit ad5ccd2d61
1 changed files with 5 additions and 0 deletions

View File

@ -866,6 +866,11 @@ plotit(wordlist *wl, char *hcopy, char *devname)
goto quit;
}
if(isinf(ylims[0]) || isinf(ylims[1])) {
fprintf(cp_err, "Error: Y values must not be infinite\n");
goto quit;
}
/* Fix the plot limits for smith and polar grids. */
if ((!xlim || !ylim) && (gtype == GRID_POLAR)) {
double mx, my, rad;