Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Massively simply the next_fib() function for doing back-off retries. In the process it fixes the following compiler warning from GCC 13.1.1 In function ‘next_fib’, inlined from ‘get_calculation’ at itsa.c:554:15: itsa.c:177:20: warning: ‘state’ may be used uninitialized [-Wmaybe-uninitialize] 177 | Fn = *state + last; | ~~~^~~~~~~~~~~~~~~ itsa.c: In function ‘get_calculation’: itsa.c:543:13: note: ‘state’ was declared here 543 | int state; | ^~~~~ We're not using threads, so there's no need for the state to be maintained externally, just use a static int in next_fib() for it. Signed-off-by: Andrew Clayton <[email protected]>
- Loading branch information