From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Sebastian Wiesner Newsgroups: gmane.emacs.bugs Subject: bug#15628: 24.3.50; ns-get-selection-internal quits on unsupported pasteboard content on OS X Date: Sun, 20 Oct 2013 14:03:32 +0200 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1382270652 27484 80.91.229.3 (20 Oct 2013 12:04:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 20 Oct 2013 12:04:12 +0000 (UTC) Cc: 15628-done@debbugs.gnu.org To: Jan =?UTF-8?Q?Dj=C3=A4rv?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Oct 20 14:04:15 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VXrjz-0008E3-4K for geb-bug-gnu-emacs@m.gmane.org; Sun, 20 Oct 2013 14:04:15 +0200 Original-Received: from localhost ([::1]:35937 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VXrjy-0006Z5-JI for geb-bug-gnu-emacs@m.gmane.org; Sun, 20 Oct 2013 08:04:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:37116) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VXrjr-0006Yy-IW for bug-gnu-emacs@gnu.org; Sun, 20 Oct 2013 08:04:12 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VXrjm-0003pL-L8 for bug-gnu-emacs@gnu.org; Sun, 20 Oct 2013 08:04:07 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:44763) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VXrjm-0003pH-Hl for bug-gnu-emacs@gnu.org; Sun, 20 Oct 2013 08:04:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1VXrjm-0007qK-17 for bug-gnu-emacs@gnu.org; Sun, 20 Oct 2013 08:04:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Sebastian Wiesner Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 20 Oct 2013 12:04:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15628 X-GNU-PR-Package: emacs,ns X-GNU-PR-Keywords: Original-Received: via spool by 15628-done@debbugs.gnu.org id=D15628.138227062230120 (code D ref 15628); Sun, 20 Oct 2013 12:04:01 +0000 Original-Received: (at 15628-done) by debbugs.gnu.org; 20 Oct 2013 12:03:42 +0000 Original-Received: from localhost ([127.0.0.1]:58782 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VXrjR-0007pj-9G for submit@debbugs.gnu.org; Sun, 20 Oct 2013 08:03:41 -0400 Original-Received: from mail-qc0-f180.google.com ([209.85.216.180]:64400) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VXrjO-0007pT-1V for 15628-done@debbugs.gnu.org; Sun, 20 Oct 2013 08:03:39 -0400 Original-Received: by mail-qc0-f180.google.com with SMTP id e9so2880100qcy.39 for <15628-done@debbugs.gnu.org>; Sun, 20 Oct 2013 05:03:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=N66ccq/WWEpCZ3M9DPbjz3qIcD8sGe0OXhPQTpS2GRk=; b=UIgZHH7Seosa24ZJrzC+Jyxqd4c/vjxMoVvZKtSXIznhR99zYceo8cMKaspING3sLG kDqggR2K9X2efvjtKzVlT8oVKOzbGYfgYBW+FWNN0tLuhDSTlLorkmmDLch2CfoJ06Iw bwhmSOT8Utm2rPxgNwKuzhyOIFDl55pTVwuzSn+z13Qn3o9rgztaTXwQdafKqGffzR+7 NSFkgqbRh2u/CwB2K3tyVDv4cG3EOzySoGlRgOqP/F7FaTaX9qkZULMBI8DFO+ieKNb8 H3hIn0cw6aNZnoSoYCvKvX55kFSY/+Et98TSJr9ITLvbfNCQsAfBoTgwXj5bonnLNXpo g4FA== X-Received: by 10.224.68.71 with SMTP id u7mr16943468qai.52.1382270612198; Sun, 20 Oct 2013 05:03:32 -0700 (PDT) Original-Received: by 10.224.78.11 with HTTP; Sun, 20 Oct 2013 05:03:32 -0700 (PDT) In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:79416 Archived-At: 2013/10/16 Jan Dj=C3=A4rv : > Hello. > > I've removed the FQuit in trunk. Great, thank you! > Jan D. > > 16 okt 2013 kl. 09:11 skrev Sebastian Wiesner : > >> >> On OS X 10.8, "ns-get-selection-internal" calls quit on unsupported >> pasteboard content, such as images. >> >> This behaviour breaks all yanking and killing. The quit signal >> interrupts "kill-new" and "current-kill" while these functions try to >> retrieve the pasteboard content via "ns-get-pasteboard" (called by >> "x-selection-value", which is the default "interprogram-paste-function" >> on OS X), which internally calls "ns-get-selection-internal". >> >> Hence, "kill-new" fails to save the given kill to the kill ring, and >> "current-kill" fails to pop the latest kill from the kill ring. >> >> To reproduce, start Emacs, set "save-interprogram-paste-before-kill" to >> t, copy an image (e.g. from an iPhoto Library), and then try to yank or >> kill. For the latter, the following stacktrace is given with >> "debug-on-quit": >> >> Debugger entered--Lisp error: (quit "empty or unsupported pasteboard typ= e") >> ns-get-selection-internal(CLIPBOARD) >> ns-get-pasteboard() >> x-selection-value() >> kill-new(#("elisp-slime-nav" 0 15 (fontified t face font-lock-constant-= face))) >> copy-region-as-kill(39166 39181) >> kill-ring-save(39166 39181) >> #(kill-ring-save nil nil) >> ad-Advice-call-interactively(# kill-ring-save = nil nil) >> apply(ad-Advice-call-interactively # (kill-rin= g-save nil nil)) >> call-interactively(kill-ring-save nil nil) >> command-execute(kill-ring-save) >> >> This unfortunate interaction makes "save-interprogram-paste-before-kill" >> nearly useless on OS X, because the user always needs to inspect the >> pasteboard manually and remove content unsupported by Emacs before being >> able to reliably kill and yank. >> >> I think "ns-get-selection-interal" should simply ignore unknown >> pasteboard content, or at least respect a user option to ignore unknown >> pasteboard content. This unknown content is of no use to Emacs anyway, >> so there is no point in even trying to put it onto the kill ring. >> >> >