Skip to content

Commit

Permalink
Account for missing histnos with histfindnodups
Browse files Browse the repository at this point in the history
Fixes issue #280.
  • Loading branch information
marlonrichert committed Jun 7, 2021
1 parent 33e193b commit 345bd48
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion completion/_autocomplete.history_lines
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ _autocomplete.history_lines() {
fi
if [[ -o histfindnodups ]]; then
while (( $#events[@] < max_lines && 0 < histno && histno < HISTNO )); do
[[ -v events[$history[$histno]] ]] ||
[[ -v history[$histno] && ! -v events[$history[$histno]] ]] &&
events[$history[$histno]]=$histno
(( histno += inc ))
done
Expand Down

0 comments on commit 345bd48

Please sign in to comment.