From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:403:478a::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id SKEtDNYsLWUuxwAAG6o9tA:P1 (envelope-from ) for ; Mon, 16 Oct 2023 14:30:14 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:478a::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id SKEtDNYsLWUuxwAAG6o9tA (envelope-from ) for ; Mon, 16 Oct 2023 14:30:14 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 9C18444E1C for ; Mon, 16 Oct 2023 14:30:13 +0200 (CEST) Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=hrdl.eu header.s=mail header.b="sIP6e6/D"; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=reject) header.from=hrdl.eu ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1697459414; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=xi15lC18YCNAD9he1NzPyOx69LIuZe+CFWgoktAs9FI=; b=pOsEPQG6AJj3V6nVuZ0HEsKGps4TGiakx7uVJkBwSdpHLfXJZu8H32J3lKX9H/ox+XWcpI egoFGLTGKLrcZelur60MDp9kpVpEhF6t4KmI1TsctjOs/zA+s3QaUprqCaSfmRJWjnDouP CTRSHzZDnJjs+dRwz0FH4fYAQhXHLu1fFE8F0ruMcrujiR5vEkio9tOqyN1acyaEliqjbJ VGH57sCJmgHmKfJ7/zrddd/b3vHjzBwUF++9IAAaL5IYo5RP7iwespfP4mJ5npblAe+A84 VRvDWG10Mz6vF7b4oK4UVIwL3XdBzVvVXdFInS+xEj0UlEbrwCyMJUIueJm/+g== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1697459414; a=rsa-sha256; cv=none; b=Tj4sHmLFcLt2QvdkC6HEQuTq5iSUt+l+4DtqRa5tKCzihRToSUlmyRFnmhXYFBVnw6JnCJ 7526g8G5SQ2IX+oOOpvDpryd9MZsO8kswOjURWgBwYDHmKVXjj0j8f4GyHChmtGKAkF9hl exIu4Yf+atvVJI2P2ZKx+Ft8LtPtiCppOKfXQHM4dfLL7qCI1FgZEX7yZ+NYeFMjGGkIdK EKMEHatgveJDbaQQMpYSCDMgqTA2mL12Pz8f4jDsOh6Y1XpWQMkD8LFUg7/C4qPJLE9dJe o8ao3K6zPxBKjKv/th/HwkwFitFNcAOUMki7mZpY3IOZ2KnOpeicKCUJGtk18g== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=hrdl.eu header.s=mail header.b="sIP6e6/D"; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=reject) header.from=hrdl.eu Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qsMiL-0007kP-8L; Mon, 16 Oct 2023 08:28:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qsKdo-0002Gr-Cp for emacs-orgmode@gnu.org; Mon, 16 Oct 2023 06:16:04 -0400 Received: from mail.hrdl.eu ([2a0a:4cc0:1:1b9::1]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qsKdj-0000ws-6l for emacs-orgmode@gnu.org; Mon, 16 Oct 2023 06:16:04 -0400 From: hrdl DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hrdl.eu; s=mail; t=1697451352; bh=xi15lC18YCNAD9he1NzPyOx69LIuZe+CFWgoktAs9FI=; h=From:To:Cc:Subject:Date; b=sIP6e6/DtGkDddACki3nCu3DtQ70s5U8MA8vgWZ/tRvjtiNJ/LUP7/ZW5Zq7cYVoO RyxVnwFmtNkFn5PtCDjahWnf/J+m+Gdl0umj8Vg9w5agHll4FIuyc8t14l2F36NDP7 zK/Op4iPNJECmmE23a7VODwVPK++71viJcT4lrqw= To: emacs-orgmode@gnu.org Cc: hrdl Subject: [PATCH] ob-core: Fix `org-babel-result-names' Date: Mon, 16 Oct 2023 11:53:25 +0200 Message-ID: <20231016101503.776938-1-git@hrdl.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2a0a:4cc0:1:1b9::1; envelope-from=git@hrdl.eu; helo=mail.hrdl.eu X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, T_SPF_TEMPERROR=0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Mon, 16 Oct 2023 08:28:52 -0400 X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Spam-Score: -5.87 X-Migadu-Queue-Id: 9C18444E1C X-Migadu-Scanner: mx0.migadu.com X-Migadu-Spam-Score: -5.87 X-TUID: NJTmgg8JX7cK * lisp/ob-core.el (org-babel-result-names): Do not change visibility of windows when called. TINYCHANGE --- lisp/ob-core.el | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lisp/ob-core.el b/lisp/ob-core.el index a7c4f2cab..54dcf400e 100644 --- a/lisp/ob-core.el +++ b/lisp/ob-core.el @@ -2015,12 +2015,12 @@ buffer or nil if no such result exists." (defun org-babel-result-names (&optional file) "Return the names of results in FILE or the current buffer." - (save-excursion - (when file (find-file file)) (goto-char (point-min)) - (let ((case-fold-search t) names) + (with-current-buffer (if file (find-file-noselect file) (current-buffer)) + (org-with-point-at 1 + (let ((case-fold-search t) names) (while (re-search-forward org-babel-result-w-name-regexp nil t) (setq names (cons (match-string-no-properties 9) names))) - names))) + names)))) ;;;###autoload (defun org-babel-next-src-block (&optional arg) -- 2.42.0