mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
; Fix regexp in ERC test-server utility
* test/lisp/erc/resources/erc-d/erc-d-i.el (erc-d-i--tag-unescaped-regexp): Thanks to Mattias and relint for catching this.
This commit is contained in:
parent
8a098f6517
commit
0a0ec8958a
1 changed files with 3 additions and 5 deletions
|
|
@ -39,14 +39,14 @@ UTF-8 text before parsing, which is nonstandard."
|
|||
(defconst erc-d-i--tag-escapes
|
||||
'((";" . "\\:") (" " . "\\s") ("\\" . "\\\\") ("\r" . "\\r") ("\n" . "\\n")))
|
||||
|
||||
;; XXX these are not mirror inverses; unescaping may degenerate
|
||||
;; original by dropping stranded/misplaced backslashes.
|
||||
;; These are not mirror inverses; unescaping may drop stranded or
|
||||
;; misplaced backslashes.
|
||||
|
||||
(defconst erc-d-i--tag-escaped-regexp (rx (or ?\; ?\ ?\\ ?\r ?\n)))
|
||||
|
||||
(defconst erc-d-i--tag-unescaped-regexp
|
||||
(rx (or "\\:" "\\s" "\\\\" "\\r" "\\n"
|
||||
(seq "\\" (or string-end (not (or ":" "n" "r" "\\")))))))
|
||||
(seq "\\" (or string-end (not (or ":" "s" "n" "r" "\\")))))))
|
||||
|
||||
(defun erc-d-i--unescape-tag-value (str)
|
||||
"Undo substitution of char placeholders in raw tag value STR."
|
||||
|
|
@ -65,8 +65,6 @@ UTF-8 text before parsing, which is nonstandard."
|
|||
|
||||
(defconst erc-d-i--invalid-tag-regexp (rx (any "\0\7\r\n; ")))
|
||||
|
||||
;; This is `erc-v3-message-tags' with fatal errors.
|
||||
|
||||
(defun erc-d-i--validate-tags (raw)
|
||||
"Validate tags portion of some RAW incoming message.
|
||||
RAW must not have a leading \"@\" or a trailing space. The spec says
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue