| 2031 | } |
| 2032 | |
| 2033 | static enum payment_step payment_aggregate_states(struct payment *p) |
| 2034 | { |
| 2035 | enum payment_step agg = p->step; |
| 2036 | |
| 2037 | for (size_t i=0; i<tal_count(p->children); i++) |
| 2038 | agg |= payment_aggregate_states(p->children[i]); |
| 2039 | |
| 2040 | return agg; |
| 2041 | } |
| 2042 | |
| 2043 | /* A payment is finished if a) it is in a final state, of b) it's in a |
| 2044 | * child-spawning state and all of its children are in a final state. */ |
no outgoing calls
no test coverage detected