| 2155 | } |
| 2156 | |
| 2157 | staticfn void |
| 2158 | cmdbind_remove(uchar key) |
| 2159 | { |
| 2160 | struct Cmd_bind *bind = gc.Cmd.cmdbinds; |
| 2161 | struct Cmd_bind *prev = (struct Cmd_bind *) 0; |
| 2162 | |
| 2163 | while (bind) { |
| 2164 | if (bind->key == key) { |
| 2165 | if (prev) |
| 2166 | prev->next = bind->next; |
| 2167 | else |
| 2168 | gc.Cmd.cmdbinds = bind->next; |
| 2169 | if (bind->param) |
| 2170 | free(bind->param); |
| 2171 | free(bind); |
| 2172 | return; |
| 2173 | } |
| 2174 | prev = bind; |
| 2175 | bind = bind->next; |
| 2176 | } |
| 2177 | } |
| 2178 | |
| 2179 | void |
| 2180 | cmdbind_freeall(void) |
no outgoing calls
no test coverage detected