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#58028: 29.0.50; Ensures no leakage of glyph_matrix Date: Sat, 24 Sep 2022 15:31:07 +0300 Message-ID: <83czblned0.fsf@gnu.org> References: <87illenmjk.fsf@elite.giraud> <83sfkiozub.fsf@gnu.org> <87czbmnksr.fsf@elite.giraud> <83k05uoujl.fsf@gnu.org> <878rm9om7q.fsf@elite.giraud> <834jwxpbo3.fsf@gnu.org> <874jwxnk02.fsf@elite.giraud> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32780"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 58028@debbugs.gnu.org To: Manuel Giraud Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Sep 24 14:55:29 2022 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 1oc4gr-0008O9-BR for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 24 Sep 2022 14:55:29 +0200 Original-Received: from localhost ([::1]:44760 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oc4go-00008q-J3 for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 24 Sep 2022 08:55:27 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:49998) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oc4KA-0006it-J1 for bug-gnu-emacs@gnu.org; Sat, 24 Sep 2022 08:32:09 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:43533) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oc4KA-0001tJ-B1 for bug-gnu-emacs@gnu.org; Sat, 24 Sep 2022 08:32:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oc4KA-0000XK-0h for bug-gnu-emacs@gnu.org; Sat, 24 Sep 2022 08:32:02 -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, 24 Sep 2022 12:32:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 58028 X-GNU-PR-Package: emacs Original-Received: via spool by 58028-submit@debbugs.gnu.org id=B58028.16640226912024 (code B ref 58028); Sat, 24 Sep 2022 12:32:01 +0000 Original-Received: (at 58028) by debbugs.gnu.org; 24 Sep 2022 12:31:31 +0000 Original-Received: from localhost ([127.0.0.1]:42611 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oc4Jf-0000WZ-G2 for submit@debbugs.gnu.org; Sat, 24 Sep 2022 08:31:31 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:53906) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oc4Jd-0000WJ-3x for 58028@debbugs.gnu.org; Sat, 24 Sep 2022 08:31:30 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:36102) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oc4JX-0001rU-BK; Sat, 24 Sep 2022 08:31:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=SvCDGIYVmJTg+DsNwSTLDpPiSxyohBcw7d0ErXd7dGY=; b=XZiUoM+YvjLw O7E5000PLupuFOyUO/NYA8PYKlzUO2TSRgMOyBZBsQDErUT9pP5PZ0KNZgpJCeSzBDSKRoFft7Ghs zfW9M9QLolfcLEemdb70CfHx0XPRHwA5ip9V6AkWAoQS5krvYzFlmrRP7kz1vhdbY+nFkc0X3Cqpd UIuvmB8QHNi53HEPESjMZFqgBbbDbfGR0aiIAxMZXcY/gNarFCyXZt5TqiMJmcUt13ReOBMAiirJU s1xv94lN8kIz/hTgsOQdHMRIaHJp6zT23xS8jlo4wZqJNRdpEYDCWrkpfDBTukx09Es8Ea+os+422 pY6Mqmo05bZ3NiFYZPPwdA==; Original-Received: from [87.69.77.57] (port=2220 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 1oc4JV-0004wO-6O; Sat, 24 Sep 2022 08:31:22 -0400 In-Reply-To: <874jwxnk02.fsf@elite.giraud> (message from Manuel Giraud on Sat, 24 Sep 2022 12:29:17 +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:243527 Archived-At: > From: Manuel Giraud > Cc: 58028@debbugs.gnu.org > Date: Sat, 24 Sep 2022 12:29:17 +0200 > > + eassert ((w->desired_matrix == NULL) > + && (w->current_matrix != NULL)); > if (w->desired_matrix == NULL) > - { > - w->desired_matrix = new_glyph_matrix (NULL); > - w->current_matrix = new_glyph_matrix (NULL); > - } > + w->desired_matrix = new_glyph_matrix (NULL); > + > + if (w->current_matrix == NULL) > + w->current_matrix = new_glyph_matrix (NULL); I think this should be /* If matrices are not yet allocated, allocate them now. */ if (w->desired_matrix == NULL) { w->desired_matrix = new_glyph_matrix (NULL); eassert (w->current_matrix == NULL); } if (w->current_matrix == NULL) w->current_matrix = new_glyph_matrix (NULL);