ref: 5c09a12f1591c84a6f7d52c231ba97fb151ad25a
parent: 49dc72d06eba5a4924c2e123cb8e9d8af2236de7
author: cancel <cancel@cancel.fm>
date: Thu Jan 17 01:47:06 EST 2019
Add guard against resizing past ORCA_x_MAX field size limit
--- a/tui_main.c
+++ b/tui_main.c
@@ -647,6 +647,10 @@
new_field_h = adjust_rulers_humanized(ruler_y, field_h, delta_h);
if (delta_w != 0)
new_field_w = adjust_rulers_humanized(ruler_x, field_w, delta_w);
+ if (new_field_h > ORCA_Y_MAX)
+ new_field_h = ORCA_Y_MAX;
+ if (new_field_w > ORCA_X_MAX)
+ new_field_w = ORCA_X_MAX;
if (new_field_h == field_h && new_field_w == field_w)
return false;
ged_resize_grid(field, markmap, new_field_h, new_field_w, tick_num,