From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#49782: 28.0.50; set-fontset-font crashes in init (server) Date: Sat, 31 Jul 2021 16:23:33 +0300 Message-ID: <837dh6pqga.fsf@gnu.org> References: <87mtq4rmh0.fsf@arrian.i-did-not-set--mail-host-address--so-tickle-me> <83eebfrixt.fsf@gnu.org> <871r7fhcpv.fsf@turtle-trading.net> <835ywrr5ve.fsf@gnu.org> <87wnp77gdn.fsf@turtle-trading.net> <83wnp7po2q.fsf@gnu.org> <8735ru3a6v.fsf@turtle-trading.net> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25544"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 49782-done@debbugs.gnu.org To: Benjamin Riefenstahl Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jul 31 15:24:14 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m9oyL-0006M6-NE for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 31 Jul 2021 15:24:13 +0200 Original-Received: from localhost ([::1]:49570 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m9oyF-00007u-9e for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 31 Jul 2021 09:24:07 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35616) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m9oyA-00007V-5K for bug-gnu-emacs@gnu.org; Sat, 31 Jul 2021 09:24:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:50221) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m9oy9-0000e7-Tv for bug-gnu-emacs@gnu.org; Sat, 31 Jul 2021 09:24:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1m9oy9-00045r-LR for bug-gnu-emacs@gnu.org; Sat, 31 Jul 2021 09:24:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 31 Jul 2021 13:24:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49782 X-GNU-PR-Package: emacs Original-Received: via spool by 49782-done@debbugs.gnu.org id=D49782.162773783515723 (code D ref 49782); Sat, 31 Jul 2021 13:24:01 +0000 Original-Received: (at 49782-done) by debbugs.gnu.org; 31 Jul 2021 13:23:55 +0000 Original-Received: from localhost ([127.0.0.1]:33534 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m9oy2-00045X-V4 for submit@debbugs.gnu.org; Sat, 31 Jul 2021 09:23:55 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:37792) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m9oy0-00045K-Re for 49782-done@debbugs.gnu.org; Sat, 31 Jul 2021 09:23:53 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:48260) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m9oxv-0000Xi-Cl; Sat, 31 Jul 2021 09:23:47 -0400 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:3426 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m9oxu-0003Cg-V8; Sat, 31 Jul 2021 09:23:47 -0400 In-Reply-To: <8735ru3a6v.fsf@turtle-trading.net> (message from Benjamin Riefenstahl on Sat, 31 Jul 2021 15:05:44 +0200) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:210981 Archived-At: > From: Benjamin Riefenstahl > Cc: 49782-done@debbugs.gnu.org > Date: Sat, 31 Jul 2021 15:05:44 +0200 > > > But before you embark on that adventure, please try another stab in > > the dark: > > > > diff --git a/src/fontset.c b/src/fontset.c > > index d2d428d..7d4bd65 100644 > > --- a/src/fontset.c > > +++ b/src/fontset.c > > @@ -1356,15 +1356,16 @@ check_fontset_name (Lisp_Object name, Lisp_Object *frame) > > int id; > > struct frame *f = decode_live_frame (*frame); > > > > - if (!FRAME_WINDOW_P (f) && !FRAME_INITIAL_P (f)) > > - error ("Can't use fontsets in non-GUI frames"); > > - > > XSETFRAME (*frame, f); > > > > if (EQ (name, Qt)) > > return Vdefault_fontset; > > if (NILP (name)) > > - id = FRAME_FONTSET (f); > > + { > > + if (!FRAME_WINDOW_P (f)) > > + error ("Can't use fontsets in non-GUI frames"); > > + id = FRAME_FONTSET (f); > > + } > > else > > { > > CHECK_STRING (name); > > Yes, this works. It works for running Emacs directly as well as through > 'emacsclient -a ""' and 'emacsclient -a "emacs"'. I think this is it. Great, thanks.