* shrink_worm() * * Remove the tail segment of the worm (the starting segment of the list). */
| 172 | * Remove the tail segment of the worm (the starting segment of the list). |
| 173 | */ |
| 174 | staticfn void |
| 175 | shrink_worm(int wnum) /* worm number */ |
| 176 | { |
| 177 | struct wseg *seg; |
| 178 | |
| 179 | if (wtails[wnum] == wheads[wnum]) |
| 180 | return; /* no tail */ |
| 181 | |
| 182 | seg = wtails[wnum]; |
| 183 | wtails[wnum] = seg->nseg; |
| 184 | seg->nseg = (struct wseg *) 0; |
| 185 | toss_wsegs(seg, TRUE); |
| 186 | } |
| 187 | |
| 188 | /* |
| 189 | * worm_move() |
no test coverage detected