From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alan Third Newsgroups: gmane.emacs.devel Subject: macOS fullscreen crashes Date: Fri, 30 Nov 2018 11:04:58 +0000 Message-ID: <20181130110458.GA54580@breton.holly.idiocy.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="pf9I7BMVVzbSWLtt" Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1543575788 13645 195.159.176.226 (30 Nov 2018 11:03:08 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 30 Nov 2018 11:03:08 +0000 (UTC) User-Agent: Mutt/1.10.1 (2018-07-13) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Nov 30 12:03:04 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gSgZb-0003RR-Vi for ged-emacs-devel@m.gmane.org; Fri, 30 Nov 2018 12:03:04 +0100 Original-Received: from localhost ([::1]:59345 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gSgbi-0002Wv-96 for ged-emacs-devel@m.gmane.org; Fri, 30 Nov 2018 06:05:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:36098) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gSgbc-0002Vm-D4 for emacs-devel@gnu.org; Fri, 30 Nov 2018 06:05:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gSgba-0002Ka-Jr for emacs-devel@gnu.org; Fri, 30 Nov 2018 06:05:08 -0500 Original-Received: from mail-wm1-x32a.google.com ([2a00:1450:4864:20::32a]:36018) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gSgbZ-0002D0-Aa for emacs-devel@gnu.org; Fri, 30 Nov 2018 06:05:06 -0500 Original-Received: by mail-wm1-x32a.google.com with SMTP id a18so5295209wmj.1 for ; Fri, 30 Nov 2018 03:05:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=sender:date:from:to:subject:message-id:mime-version :content-disposition:content-transfer-encoding:user-agent; bh=2ulyHW+plxgCByFiacX1nNgWATM36cJNp4v6Kk7jLfY=; b=sBNV92w0aDy6S9WAOFFa7Z5dHTMRG5c6kbV6jTShcfDkMe9Qid3RqqcX1RAjPO9rOi veNwLQ7Y8TNTcFywZxbegLqcW1c/jft8mfG4bzBnz1A/Fq+Z6PaCryafbXkbz4ShHxx7 iH5/R4x8EOoaDotms9X4tqzUVIpahJk+GODghQuNRrOM3t9JTx1dam0J80VZqfKJopIT qePCJnX9kGjuNd3lezOzCkhTX5SJwQnWQzD8otsj5iWL6g1uIXr4gTf+yblyYs50zPWL axqiYcDVXzm2e8jgBK1WKweL+bbs3SNcyAXwKBNpjU/35DkdesWOYqTtQmMKDRFmqMCE km6A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:subject:message-id :mime-version:content-disposition:content-transfer-encoding :user-agent; bh=2ulyHW+plxgCByFiacX1nNgWATM36cJNp4v6Kk7jLfY=; b=UuCEFPOViD7kWu6NNWAmnazvTpT4uqmRxkQMRsmJSVOq6/AFuyhuKkc8TP13gJjQh/ kcL/uMUn77t3Q435k62OJJXSmkIhFonOm+yhP1Qs+jWXYBBJ7r/7z/VsIH1g317XRmAH 8nGinlSuFmJd9LbDIR225wRZNl95xCnlBkH16MAt3AEAhqsqpzaKLI3nQKUwQtLsC/JK olLUPJ3kL/ui8bPC74e5TQNi0yMheuy53dMasHX1gphLFXHXNDd+FoqyXgqXotvjMqI1 gMs1vxXg5kFnhpZzeNWA2HNwobI4Q39oP1xr/ty3IR0LUSXbFlW40Psk9gGiyB23L9ah Jx5Q== X-Gm-Message-State: AA+aEWYznoia9OaA+JX30ZfqclOTX/2FkBLOsA5MeWY6T1Q0aqJgokxu 9i1H0zNBthak0fQNqYdrKeNt8MKz X-Google-Smtp-Source: AFSGD/U6kck4kT3zbzo4Bl8jtVNQQ6pAy7soDJacGre1I/HVUrUb53rrEPQ/zyYQAQDqesivrsty+A== X-Received: by 2002:a1c:2686:: with SMTP id m128mr4844913wmm.52.1543575901743; Fri, 30 Nov 2018 03:05:01 -0800 (PST) Original-Received: from breton.holly.idiocy.org (ip6-2001-08b0-03f8-8129-5d77-74ac-6cf9-3453.holly.idiocy.org. [2001:8b0:3f8:8129:5d77:74ac:6cf9:3453]) by smtp.gmail.com with ESMTPSA id t187-v6sm4218371wmt.45.2018.11.30.03.05.00 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 30 Nov 2018 03:05:00 -0800 (PST) Content-Disposition: inline X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::32a X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:231537 Archived-At: --pf9I7BMVVzbSWLtt Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit We still occasionally receive bug reports about crashes on macOS 10.12+ caused by macOS turning fullscreen windows into ‘tabbed’ windows. I’ve also seen it discussed in a few places round the web. We currently have a compile‐time check to include code that fixes this on 10.12+, and it can be over‐ridden if Emacs is being built on an older version of macOS but is expected to run on 10.12+, however it is clearly not doing the job. I propose for Emacs 26.2 (and the master branch) that we remove the compile‐time check and just use a run‐time check. This will result in a compiler warning on macOS 10.11 and below, but will prevent crashes everywhere. Any thoughts? Patch attached. -- Alan Third --pf9I7BMVVzbSWLtt Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="0001-Remove-macOS-version-checks-for-tabbed-frames-bug-33.patch" >From 4df81ee31f0f2cf9ca4f906d753cf7dd134cf64d Mon Sep 17 00:00:00 2001 From: Alan Third Date: Fri, 30 Nov 2018 10:50:44 +0000 Subject: [PATCH] Remove macOS version checks for tabbed frames (bug#33118) * src/nsterm.m ([EmacsView initFrameFromEmacs:]) [NS_IMPL_COCOA]: Remove compile-time version checks. --- src/nsterm.m | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/nsterm.m b/src/nsterm.m index 948dd1da2e..7a751b3868 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -7397,14 +7397,16 @@ - (instancetype) initFrameFromEmacs: (struct frame *)f [NSApp registerServicesMenuSendTypes: ns_send_types returnTypes: [NSArray array]]; +#if defined (NS_IMPL_COCOA) /* macOS Sierra automatically enables tabbed windows. We can't allow this to be enabled until it's available on a Free system. - Currently it only happens by accident and is buggy anyway. */ -#if defined (NS_IMPL_COCOA) \ - && MAC_OS_X_VERSION_MAX_ALLOWED >= 101200 -#if MAC_OS_X_VERSION_MIN_REQUIRED < 101200 + Currently it only happens by accident and is buggy anyway. + + This will cause a build warning on older versions of macOS, but + limiting it to just 10.12+ has resulted in a number of crash + reports where Emacs was built on an older version of macOS than + it's being used on. */ if ([win respondsToSelector: @selector(setTabbingMode:)]) -#endif [win setTabbingMode: NSWindowTabbingModeDisallowed]; #endif -- 2.19.1 --pf9I7BMVVzbSWLtt--