| 26 | */ |
| 27 | |
| 28 | void |
| 29 | init_rect(void) |
| 30 | { |
| 31 | if (!rect) { |
| 32 | n_rects = (COLNO * ROWNO) / 30; |
| 33 | rect = (NhRect *) alloc(sizeof(NhRect) * n_rects); |
| 34 | if (!rect) |
| 35 | panic("Could not alloc rect"); |
| 36 | } |
| 37 | |
| 38 | rect_cnt = 1; |
| 39 | rect[0].lx = rect[0].ly = 0; |
| 40 | rect[0].hx = COLNO - 1; |
| 41 | rect[0].hy = ROWNO - 1; |
| 42 | } |
| 43 | |
| 44 | void |
| 45 | free_rect(void) |
no test coverage detected