From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:403:478a::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id 0CnsMjui+mQzSwAAauVa8A:P1 (envelope-from ) for ; Fri, 08 Sep 2023 06:25:31 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:478a::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id 0CnsMjui+mQzSwAAauVa8A (envelope-from ) for ; Fri, 08 Sep 2023 06:25:31 +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 4C3B45406E for ; Fri, 8 Sep 2023 06:25:31 +0200 (CEST) Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20221208 header.b=Crzpu9ih; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1694147131; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=4hhqzNPYd68CHmuvcJ2deuoEVJD2Nm3uigcu69jFpe8=; b=UVjlKyO16+s9YzoOHwtxO2xe1qvUjTXVlkZ3DR7GdVS8WQDmHQpoW3S3uU9i3hsyKkGJlp XrdduRmnX1KD/owakRhyiQg/W113d5qqfjJslnfOM1zyUoFBqD81io8GR2let8t19xQEnR P9WG3EONjGqzEadCVUE/9C4jv/+xfNUuuP7c0/ePck/Qx0t7W66NSXElRKxSAD1evImnLb k1jdwsvup3UAqEUbZQJ4WfT74MbNTGpDU4+4TKiYDVXc9pSPji0gJAGqWczkPS6MO/jWWI D2E3W3kgWoEg0UoDk92VmmmYUwLVred+Z5Jhga5UIblshb7PFnmlwHZPj5M/8Q== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1694147131; a=rsa-sha256; cv=none; b=GsGPWsU+vpejXo56uTnUAP1rftjE9HU/Y94Htsgm0KsQgENFQYwaP0hARu58JWBNXgL3Ik 3Mw+5s0ne/igZmXzYuS+T3m7iyM2UDEEFWhphd4q1We0WTNlPq6GS6CkJiw0pZEmuT8JCP YxgSlxhOtqMxEsgplMmf7YPMOt38PviVs6Bq/bJukA0Uuz02QfBvxOm1RkrY3jJ6CNXOXO EoIKi5lX1adM+jk7B4NyTHgMlfPTolNZmOWUc/X+Aak8tthwZFKi0LPZfQKKTHA0869vID cfD3xMlnmsZQ7Bn9QW+CbrBEsSkZwugkNwuKFMODkxXNJzP4tXlidNw/UP4WkA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20221208 header.b=Crzpu9ih; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qeT3F-0000go-V8; Fri, 08 Sep 2023 00:25:01 -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 1qeT3E-0000gF-RR for guix-patches@gnu.org; Fri, 08 Sep 2023 00:25:00 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qeT3E-0007kY-7q for guix-patches@gnu.org; Fri, 08 Sep 2023 00:25:00 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qeT3G-0007lD-07 for guix-patches@gnu.org; Fri, 08 Sep 2023 00:25:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65798] [PATCH gnome-team v2] Cogl: fix double free Resent-From: Liliana Marie Prikler Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 08 Sep 2023 04:25:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65798 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Vivien Kraus , 65798@debbugs.gnu.org Cc: rg@raghavgururajan.name, maxim.cournoyer@gmail.com Received: via spool by 65798-submit@debbugs.gnu.org id=B65798.169414706929786 (code B ref 65798); Fri, 08 Sep 2023 04:25:01 +0000 Received: (at 65798) by debbugs.gnu.org; 8 Sep 2023 04:24:29 +0000 Received: from localhost ([127.0.0.1]:41892 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qeT2i-0007kM-Sv for submit@debbugs.gnu.org; Fri, 08 Sep 2023 00:24:29 -0400 Received: from mail-ed1-x543.google.com ([2a00:1450:4864:20::543]:60512) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qeT2d-0007k3-LM for 65798@debbugs.gnu.org; Fri, 08 Sep 2023 00:24:27 -0400 Received: by mail-ed1-x543.google.com with SMTP id 4fb4d7f45d1cf-522bd411679so2196011a12.0 for <65798@debbugs.gnu.org>; Thu, 07 Sep 2023 21:24:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1694147055; x=1694751855; darn=debbugs.gnu.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:from:to:cc:subject :date:message-id:reply-to; bh=4hhqzNPYd68CHmuvcJ2deuoEVJD2Nm3uigcu69jFpe8=; b=Crzpu9ihN929p77GF5KIJINcGfEeR1H+WGRxN0W4j2HV2rteirwqzmzZwnM04cTG/y L8modWPEewPlUOhkigSGy4/nMSo9fIo53nO7X1EMMxdR6hFr0qXLqkwY7sKs70ljvvHp CWobPFmE9hb7QQ2WDJMaqowsnhYDxeT3blUUTrpF7N6q9iMrhUKngFwoZuCeP9xYvZhw +coILu+rPiQwv4DZhq06MSlQlzHXrPvzVVu5ymCnNo31PjiVP0WQMFX7wY32CBVCA6U0 e6Og0eKzPieZShTM/4HTWopQA64tO0vXXqiDaNJse4Fcvd+qYthd2HdU9r7NGC6oJhz0 SFCA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694147055; x=1694751855; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=4hhqzNPYd68CHmuvcJ2deuoEVJD2Nm3uigcu69jFpe8=; b=PyZLwogowp9DOih6yv0rD/OVwubo1ZPi/MpFyqCBYkDpkSceTr5Rz75velwB4AK4++ YEStyBiQEuEqFX/DlaluOG+5Kxm36La56+XtUjE0tj91FjLFJ+XFiWWf8Zd4dAUSfRrK 8E5aXJz7DLQP9ZyCyPsLikJ1Dn7wvK/nDIYjeqbSYPklNsu1pnYbUqUMdWmWuTi3hoQl fMuarGznYgyo/wZdCpSmN9EkalduO9HHrmv2JtKynNSdFc+1GREopf3Hu10NPHMe+iK6 rtM9dxGMLJCJ2onnih8TEYAffiZVav1dfnq2B9iFh0kUEihtGz4Gkwd+GNJNgDE/jg3N LxGw== X-Gm-Message-State: AOJu0YzbJHqlk6brvJGUuhX4rPYMK/HhBN8ceHkC1pKnScnxdf6v3NGw zOdNOn9AJwM7Fy5FTmrTq2k= X-Google-Smtp-Source: AGHT+IFdOS7vZCBVkHJb5yA9TCJW7DcQU3L0a55s+0D26jz8iCf7w0AsGy2Pti8JFzOvWWKQO3jsDw== X-Received: by 2002:a17:906:fa81:b0:9a1:cb2c:b55f with SMTP id lt1-20020a170906fa8100b009a1cb2cb55fmr885539ejb.53.1694147055312; Thu, 07 Sep 2023 21:24:15 -0700 (PDT) Received: from lumine.fritz.box (85-127-52-93.dsl.dynamic.surfer.at. [85.127.52.93]) by smtp.gmail.com with ESMTPSA id s4-20020a170906960400b00982cfe1fe5dsm468844ejx.65.2023.09.07.21.24.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Sep 2023 21:24:13 -0700 (PDT) Message-ID: From: Liliana Marie Prikler Date: Fri, 08 Sep 2023 06:24:12 +0200 In-Reply-To: <018c75fd44fa1b1462a49f5bf700b9194d9c6341.1694118524.git.vivien@planete-kraus.eu> References: <018c75fd44fa1b1462a49f5bf700b9194d9c6341.1694118524.git.vivien@planete-kraus.eu> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.46.4 MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Scanner: mx0.migadu.com X-Migadu-Spam-Score: -2.13 X-Spam-Score: -2.13 X-Migadu-Queue-Id: 4C3B45406E X-TUID: +1ln7LyORP4d Am Donnerstag, dem 07.09.2023 um 07:36 +0200 schrieb Vivien Kraus: > * gnu/local.mk (dist_patch_DATA): Add cogl-fix-double-free.patch. > * gnu/packages/gnome.scm (cogl): Apply cogl-fix-double-free.patch. > * gnu/packages/patches/cogl-fix-double-free.patch: Avoid freeing the > dispaly used by a cogl context twice. display Usually you do (patch, register, use) in this order, but I can rewrite the ChangeLog for you easily :) > Since the cogl repository is > read-only, this patch won=E2=80=99t be applied upstream. This information is not necessary in the ChangeLog. You could mention it before that, but I think keeping it in the patch itself is a better idea. > --- > =C2=A0gnu/local.mk=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 |=C2= =A0 1 + > =C2=A0gnu/packages/gnome.scm=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0 |=C2=A0 4 ++- > =C2=A0.../patches/cogl-fix-double-free.patch=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 | 31 > +++++++++++++++++++ > =C2=A03 files changed, 35 insertions(+), 1 deletion(-) > =C2=A0create mode 100644 gnu/packages/patches/cogl-fix-double-free.patch >=20 > diff --git a/gnu/local.mk b/gnu/local.mk > index 24fa8117c6..ae36dd49c9 100644 > --- a/gnu/local.mk > +++ b/gnu/local.mk > @@ -1024,6 +1024,7 @@ dist_patch_DATA > =3D=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0\ > =C2=A0=C2=A0 %D%/packages/patches/clucene-pkgconfig.patch=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0\ > =C2=A0=C2=A0 %D%/packages/patches/cmake-curl-certificates-3.24.patch=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0\ > =C2=A0=C2=A0 %D%/packages/patches/coda-use-system-libs.patch=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0\ > +=C2=A0 %D%/packages/patches/cogl-fix-double-free.patch=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0\ > =C2=A0=C2=A0 %D%/packages/patches/collectd-5.11.0- > noinstallvar.patch=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0\ > =C2=A0=C2=A0 %D%/packages/patches/combinatorial-blas-awpm.patch=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0\ > =C2=A0=C2=A0 %D%/packages/patches/combinatorial-blas-io-fix.patch=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0\ > diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm > index 922d6ba24b..6b824c2832 100644 > --- a/gnu/packages/gnome.scm > +++ b/gnu/packages/gnome.scm > @@ -6131,7 +6131,9 @@ (define-public cogl > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 (version-major+minor version) "/" > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 "cogl-" version ".tar.xz")) > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (sha256 > -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (base32 > "0nfph4ai60ncdx7hy6hl1i1cmp761jgnyjfhagzi0iqq36qb41d8")))) > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (base32 > "0nfph4ai60ncdx7hy6hl1i1cmp761jgnyjfhagzi0iqq36qb41d8")) > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (patches > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (search-patches "cogl-fix-dou= ble-free.patch")))) > =C2=A0=C2=A0=C2=A0=C2=A0 ;; NOTE: mutter exports a bundled fork of cogl, = so when making > changes to > =C2=A0=C2=A0=C2=A0=C2=A0 ;; cogl, corresponding changes may be appropriat= e in mutter as > well. This comment no longer applies to current mutter, for it has diverged far enough. > =C2=A0=C2=A0=C2=A0=C2=A0 (build-system gnu-build-system) > diff --git a/gnu/packages/patches/cogl-fix-double-free.patch > b/gnu/packages/patches/cogl-fix-double-free.patch > new file mode 100644 > index 0000000000..7094c4cf02 > --- /dev/null > +++ b/gnu/packages/patches/cogl-fix-double-free.patch > @@ -0,0 +1,31 @@ > +From 38d3fda8849ac327b473ac11dfac5499f595b7ac Mon Sep 17 00:00:00 > 2001 > +Message-ID: > <38d3fda8849ac327b473ac11dfac5499f595b7ac.1694118000.git.vivien@plane > te-kraus.eu> > +In-Reply-To: > +References: > +From: Vivien Kraus > +Date: Thu, 7 Sep 2023 22:16:48 +0200 > +Subject: [PATCH 1/1] Prevent double free on context objects > + > +The display is unrefed in the context destructor, but not refed in > the > +constructor. > + > +This targets an archived (read-only) repository. > +--- > + cogl/cogl-context.c | 1 + > + 1 file changed, 1 insertion(+) > + > +diff --git a/cogl/cogl-context.c b/cogl/cogl-context.c > +index a7eed29a..22809424 100644 > +--- a/cogl/cogl-context.c > ++++ b/cogl/cogl-context.c > +@@ -219,6 +219,7 @@ cogl_context_new (CoglDisplay *display, > +=C2=A0=C2=A0=C2=A0=C2=A0 } > +=20 > +=C2=A0=C2=A0 context->display =3D display; > ++=C2=A0 cogl_object_ref (display); You can use context->display =3D cogl_object_ref (display) if it works like g_object_ref. > +=20 > +=C2=A0=C2=A0 /* This is duplicated data, but it's much more convenient t= o have > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 the driver attached to the context and th= e value is accessed a > +--=20 > +2.41.0 > + >=20 > base-commit: baf5b0745446dabe8166d860996dc54cfa09db3e Will see what CI has to say, otherwise LGTM. Cheers