* Returns the number of unpaid items within the given list. This includes * contained objects. */
| 3523 | * contained objects. |
| 3524 | */ |
| 3525 | int |
| 3526 | count_unpaid(struct obj *list) |
| 3527 | { |
| 3528 | int count = 0; |
| 3529 | |
| 3530 | while (list) { |
| 3531 | if (list->unpaid) |
| 3532 | count++; |
| 3533 | if (Has_contents(list)) |
| 3534 | count += count_unpaid(list->cobj); |
| 3535 | list = list->nobj; |
| 3536 | } |
| 3537 | return count; |
| 3538 | } |
| 3539 | |
| 3540 | /* |
| 3541 | * Returns the number of items with b/u/c/unknown within the given list. |
no outgoing calls
no test coverage detected