{"id":19561,"url":"https://patchwork.libcamera.org/api/1.1/covers/19561/?format=json","web_url":"https://patchwork.libcamera.org/cover/19561/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20240227175336.560009-1-nicolas@ndufresne.ca>","date":"2024-02-27T17:53:33","name":"[v1,0/3] gstreamer: Fix a crash when memory outlives the pipeline","submitter":{"id":30,"url":"https://patchwork.libcamera.org/api/1.1/people/30/?format=json","name":"Nicolas Dufresne","email":"nicolas@ndufresne.ca"},"mbox":"https://patchwork.libcamera.org/cover/19561/mbox/","series":[{"id":4190,"url":"https://patchwork.libcamera.org/api/1.1/series/4190/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=4190","date":"2024-02-27T17:53:33","name":"gstreamer: Fix a crash when memory outlives the pipeline","version":1,"mbox":"https://patchwork.libcamera.org/series/4190/mbox/"}],"comments":"https://patchwork.libcamera.org/api/covers/19561/comments/","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id ECB72BD160\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue, 27 Feb 2024 17:53:59 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id F25F362867;\n\tTue, 27 Feb 2024 18:53:58 +0100 (CET)","from madrid.collaboradmins.com (madrid.collaboradmins.com\n\t[IPv6:2a00:1098:ed:100::25])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 09C7162806\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 27 Feb 2024 18:53:57 +0100 (CET)","from nicolas-tpx395.lan (cola.collaboradmins.com [195.201.22.229])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\tkey-exchange X25519 server-signature RSA-PSS (4096 bits)\n\tserver-digest SHA256)\n\t(No client certificate requested) (Authenticated sender: nicolas)\n\tby madrid.collaboradmins.com (Postfix) with ESMTPSA id 5556C378000B; \n\tTue, 27 Feb 2024 17:53:56 +0000 (UTC)"],"From":"Nicolas Dufresne <nicolas@ndufresne.ca>","To":"libcamera-devel@lists.libcamera.org","Subject":"[PATCH v1 0/3] gstreamer: Fix a crash when memory outlives the\n\tpipeline","Date":"Tue, 27 Feb 2024 12:53:33 -0500","Message-ID":"<20240227175336.560009-1-nicolas@ndufresne.ca>","X-Mailer":"git-send-email 2.43.2","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Cc":"Nicolas Dufresne <nicolas.dufresne@collabora.com>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"From: Nicolas Dufresne <nicolas.dufresne@collabora.com>\n\nThis set fixes a memory lifetime issue which in the end happens because the\ncamera manager needs to outlive all of its object, including the\nFrameBufferAllocator. This is fixing a crash reported at:\n\nhttps://bugs.libcamera.org/show_bug.cgi?id=211\n\nNicolas Dufresne (3):\n  gstreamer: allocator: Ensure camera manager stay alive\n  test: gstreamer: Simplify single stream test\n  test: gstreamer: Test memory lifetime\n\n src/gstreamer/gstlibcameraallocator.cpp       | 16 +++-\n .../gstreamer_memory_lifetime_test.cpp        | 75 +++++++++++++++++++\n .../gstreamer_single_stream_test.cpp          | 27 +++----\n test/gstreamer/meson.build                    |  4 +-\n 4 files changed, 102 insertions(+), 20 deletions(-)\n create mode 100644 test/gstreamer/gstreamer_memory_lifetime_test.cpp"}