Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH 3/5: Wrong memcmp variant used in getvirange()
- X-seq: zsh-workers 54480
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: PATCH 3/5: Wrong memcmp variant used in getvirange()
- Date: Wed, 6 May 2026 11:23:32 +0200
- Archived-at: <https://zsh.org/workers/54480>
- List-id: <zsh-workers.zsh.org>
Spotted this while looking for zlell assignments, I'm not sure exactly
what the consequence was but presumably things sometimes went wrong.
---
Src/Zle/zle_vi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Src/Zle/zle_vi.c b/Src/Zle/zle_vi.c
index 667063774d..86543e172a 100644
--- a/Src/Zle/zle_vi.c
+++ b/Src/Zle/zle_vi.c
@@ -233,7 +233,7 @@ getvirange(int wf)
/* It is an error to use a non-movement command to delimit the *
* range. We here reject the case where the command modified *
* the line, or selected a different history line. */
- if (histline != hist1 || zlell != lastll || memcmp(zleline, lastline, zlell)) {
+ if (histline != hist1 || zlell != lastll || ZS_memcmp(zleline, lastline, zlell)) {
histline = hist1;
ZS_memcpy(zleline, lastline, zlell = lastll);
zlecs = pos;
--
2.38.1
Messages sorted by:
Reverse Date,
Date,
Thread,
Author