| 969 | } |
| 970 | |
| 971 | static void |
| 972 | test_alloc_unr(struct unrhdr *uh, u_int i, char a[]) |
| 973 | { |
| 974 | int j; |
| 975 | |
| 976 | if (a[i]) { |
| 977 | VPRINTF("F %u\n", i); |
| 978 | free_unr(uh, i); |
| 979 | a[i] = 0; |
| 980 | } else { |
| 981 | no_alloc = 1; |
| 982 | j = alloc_unr(uh); |
| 983 | if (j != -1) { |
| 984 | a[j] = 1; |
| 985 | VPRINTF("A %d\n", j); |
| 986 | } |
| 987 | no_alloc = 0; |
| 988 | } |
| 989 | } |
| 990 | |
| 991 | static void |
| 992 | test_alloc_unr_specific(struct unrhdr *uh, u_int i, char a[]) |