# HG changeset patch # User Jan Dj¸«£rv # Date 1107622402 0 # Node ID c7c51386376cb88d5b1d48b14a95531f4ef15ff5 # Parent f5f2fbf049bc03f8bedf50c7c88eae351887065f * x-dnd.el (x-dnd-handle-xdnd): Handle the case where the flags isn't a cons (i.e. the version is 0). diff -r f5f2fbf049bc -r c7c51386376c lisp/ChangeLog --- a/lisp/ChangeLog Sat Feb 05 16:41:38 2005 +0000 +++ b/lisp/ChangeLog Sat Feb 05 16:53:22 2005 +0000 @@ -1,3 +1,8 @@ +2005-02-05 Jan Dj,Ad(Brv + + * x-dnd.el (x-dnd-handle-xdnd): Handle the case where the flags + isn't a cons (i.e. the version is 0). + 2005-02-05 Eli Zaretskii * help.el (help-for-help): Doc fix. diff -r f5f2fbf049bc -r c7c51386376c lisp/x-dnd.el --- a/lisp/x-dnd.el Sat Feb 05 16:41:38 2005 +0000 +++ b/lisp/x-dnd.el Sat Feb 05 16:53:22 2005 +0000 @@ -557,18 +557,20 @@ WINDOW is the window within FRAME where the mouse is now. FORMAT is 32 (not used). MESSAGE is the data part of an XClientMessageEvent." (cond ((equal "XdndEnter" message) - (let ((version (ash (car (aref data 1)) -8)) - (more-than-3 (cdr (aref data 1))) - (dnd-source (aref data 0))) - (x-dnd-save-state - window nil nil - (if (> more-than-3 0) - (x-window-property "XdndTypeList" - frame "AnyPropertyType" - dnd-source nil t) - (vector (x-get-atom-name (aref data 2)) - (x-get-atom-name (aref data 3)) - (x-get-atom-name (aref data 4))))))) + (let* ((flags (aref data 1)) + (version (and (consp flags) (ash (car flags) -8))) + (more-than-3 (and (consp flags) (cdr flags))) + (dnd-source (aref data 0))) + (if version ;; If flags is bad, version will be nil. + (x-dnd-save-state + window nil nil + (if (> more-than-3 0) + (x-window-property "XdndTypeList" + frame "AnyPropertyType" + dnd-source nil t) + (vector (x-get-atom-name (aref data 2)) + (x-get-atom-name (aref data 3)) + (x-get-atom-name (aref data 4)))))))) ((equal "XdndPosition" message) (let* ((x (car (aref data 2)))