]> git.eshelyaron.com Git - emacs.git/commitdiff
(search-read-target): Fix off-by-one in group-function
authorEshel Yaron <me@eshelyaron.com>
Sat, 13 Jul 2024 14:22:54 +0000 (16:22 +0200)
committerEshel Yaron <me@eshelyaron.com>
Sat, 13 Jul 2024 14:22:54 +0000 (16:22 +0200)
lisp/search.el

index 366a2aaed072168309e527f456358606669887a1..829da463282ea62488d022400281f743c8fca92b 100644 (file)
                       `((category . search)
                         (group-function
                          . ,(lambda (string &optional transform)
-                              (when transform (nth 1 (string-split string ":")))))))
-                     nil t))
+                              (when transform
+                                (substring string (1+ (string-search ":" string))))))))
+                     nil t nil t))
                    tab))
       (mapc #'delete-overlay ovs)
       (mapc #'delete-overlay ovz))))