Skip to content

Commit 87ce96b

Browse files
Merge pull request #159 from dxrcy/master
Fix user input after search
2 parents 8dd05bf + 3235b88 commit 87ce96b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

zsh-history-substring-search.zsh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -406,7 +406,7 @@ _history-substring-search-end() {
406406

407407
# For debugging purposes:
408408
# zle -R "mn: "$_history_substring_search_match_index" m#: "${#_history_substring_search_matches}
409-
# read -k -t 200 && zle -U $REPLY
409+
# read -k -t 200 && zle -U -- "$REPLY"
410410

411411
#
412412
# When this function returns, z-sy-h runs its line-pre-redraw hook. It has no
@@ -421,7 +421,7 @@ _history-substring-search-end() {
421421
# before removing search highlight and exiting. This ensures no highlights
422422
# are left lingering after search is finished.
423423
#
424-
read -k -t ${HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_TIMEOUT:-1} && zle -U $REPLY
424+
read -k -t ${HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_TIMEOUT:-1} && zle -U -- "$REPLY"
425425
region_highlight=( "${(@)region_highlight:#*${highlight_memo}*}" )
426426
fi
427427

0 commit comments

Comments
 (0)