File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
src/flamenco/runtime/program Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -1853,20 +1853,20 @@ process_vote_with_account( fd_borrowed_account_t * vote_account,
1853
1853
return FD_EXECUTOR_INSTR_ERR_CUSTOM_ERR ;
1854
1854
}
1855
1855
1856
- ulong * max = deq_ulong_peek_head ( vote -> slots ) ? deq_ulong_peek_head ( vote -> slots ) : NULL ;
1856
+ ulong max = deq_ulong_peek_head ( vote -> slots ) ? * deq_ulong_peek_head ( vote -> slots ) : 0UL ;
1857
1857
// https://github.com/anza-xyz/agave/blob/v2.0.1/programs/vote/src/vote_state/mod.rs#L1127
1858
1858
for ( deq_ulong_iter_t iter = deq_ulong_iter_init ( vote -> slots );
1859
1859
!deq_ulong_iter_done ( vote -> slots , iter );
1860
1860
iter = deq_ulong_iter_next ( vote -> slots , iter ) ) {
1861
1861
ulong * ele = deq_ulong_iter_ele ( vote -> slots , iter );
1862
- * max = fd_ulong_max ( * max , * ele );
1862
+ max = fd_ulong_max ( max , * ele );
1863
1863
}
1864
1864
if ( FD_UNLIKELY ( !max ) ) {
1865
1865
ctx -> txn_ctx -> custom_err = FD_VOTE_ERR_EMPTY_SLOTS ;
1866
1866
return FD_EXECUTOR_INSTR_ERR_CUSTOM_ERR ;
1867
1867
}
1868
1868
// https://github.com/anza-xyz/agave/blob/v2.0.1/programs/vote/src/vote_state/mod.rs#L1131
1869
- rc = process_timestamp ( & vote_state , * max , * vote -> timestamp , ctx );
1869
+ rc = process_timestamp ( & vote_state , max , * vote -> timestamp , ctx );
1870
1870
if ( FD_UNLIKELY ( rc ) ) return rc ;
1871
1871
}
1872
1872
You can’t perform that action at this time.
0 commit comments