[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Last commit to mouse.el has a bug
From: |
John Paul Wallington |
Subject: |
Re: Last commit to mouse.el has a bug |
Date: |
Thu, 28 Oct 2004 23:13:02 +0100 |
> (let (x-lost-selection-hooks (copy-sequence x-lost-selection-hooks)))
> <-- Bug here
>
> At this time, x-lost-selection-hooks is not set, so copy-sequence will
> fail.
>
> You can try to use mouse to select a region, and you'll get error
> message as:
>
> "mouse-drag-region-1: Symbol's value as variable is void:
> x-lost-selection-hooks"
>
> Just revert it to
>
> (let ((inhibit-quit t)
> (echo-keystrokes 0)
> event events key ignore
> x-lost-selection-hooks )
>
> fixes this bug.
There may be other functions on that hook that should be run. How
about testing whether it is bound before copying it?
--- mouse.el 27 Oct 2004 17:44:59 -0000 1.252
+++ mouse.el 28 Oct 2004 22:16:32 -0000
@@ -1028,7 +1028,8 @@
(let ((inhibit-quit t)
(echo-keystrokes 0)
event events key ignore
- (x-lost-selection-hooks (copy-sequence x-lost-selection-hooks)))
+ (x-lost-selection-hooks (if (boundp 'x-lost-selection-hooks)
+ (copy-sequence x-lost-selection-hooks))))
(add-hook 'x-lost-selection-hooks
(lambda (seltype)
(if (eq seltype 'PRIMARY)