* Return the timeout's I've-been-fired indicator * * If reset_indicator is true, reset the indicator when returning true. * To avoid missing timeouts due to race conditions, we are careful not to * reset the indicator when returning false. */
| 739 | * reset the indicator when returning false. |
| 740 | */ |
| 741 | bool |
| 742 | get_timeout_indicator(TimeoutId id, bool reset_indicator) |
| 743 | { |
| 744 | if (all_timeouts[id].indicator) |
| 745 | { |
| 746 | if (reset_indicator) |
| 747 | all_timeouts[id].indicator = false; |
| 748 | return true; |
| 749 | } |
| 750 | return false; |
| 751 | } |
| 752 | |
| 753 | /* |
| 754 | * Return the time when the timeout was most recently activated |