Skip to content

Commit c10626a

Browse files
committed
Correct error character display when hardmax/hardmin are exceeded.
1 parent bd80faf commit c10626a

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

ttyplot.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ static void plot_values(int ph, int pw, double *v1, double *v2, double max, doub
214214
if (v1[i] > hardmax)
215215
l1 = ph;
216216
else if (v1[i] < hardmin)
217-
l1 = 0;
217+
l1 = 1;
218218
else
219219
l1 = lrint((v1[i] - min) / (max - min) * ph);
220220

@@ -223,7 +223,7 @@ static void plot_values(int ph, int pw, double *v1, double *v2, double max, doub
223223
else if (v2[i] > hardmax)
224224
l2 = ph;
225225
else if (v2[i] < hardmin)
226-
l2 = 0;
226+
l2 = 1;
227227
else
228228
l2 = lrint((v2[i] - min) / (max - min) * ph);
229229

0 commit comments

Comments
 (0)