{"id":16499,"url":"https://patchwork.libcamera.org/api/1.1/patches/16499/?format=json","web_url":"https://patchwork.libcamera.org/patch/16499/","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":"<20220701084521.31831-8-tomi.valkeinen@ideasonboard.com>","date":"2022-07-01T08:45:11","name":"[libcamera-devel,v3,07/17] py: Set EFD_CLOEXEC on eventfd to avoid fd leaking","commit_ref":null,"pull_url":null,"state":"accepted","archived":false,"hash":"91ab40ddae689e948ba2786b80bf5cde2d63b075","submitter":{"id":109,"url":"https://patchwork.libcamera.org/api/1.1/people/109/?format=json","name":"Tomi Valkeinen","email":"tomi.valkeinen@ideasonboard.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/16499/mbox/","series":[{"id":3241,"url":"https://patchwork.libcamera.org/api/1.1/series/3241/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=3241","date":"2022-07-01T08:45:04","name":"Python bindings event handling","version":3,"mbox":"https://patchwork.libcamera.org/series/3241/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/16499/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/16499/checks/","tags":{},"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 DEFD3BD808\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri,  1 Jul 2022 08:45:51 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id BDE1765662;\n\tFri,  1 Jul 2022 10:45:50 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 0A52265659\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri,  1 Jul 2022 10:45:44 +0200 (CEST)","from deskari.lan (91-158-154-79.elisa-laajakaista.fi\n\t[91.158.154.79])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 710DF25C;\n\tFri,  1 Jul 2022 10:45:43 +0200 (CEST)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1656665151;\n\tbh=4jssbuxUq5C1GVY59JXBlIIcwKau4KEUhfDWEvwAuHc=;\n\th=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\n\tFrom;\n\tb=zNJtsdU3luPxDfdTCVNynzzZSCzkq54Xw6/WnxnLgHfeIrwnzGyA2Zry8avA2P3ja\n\t7XdOYbD/1qJbrx/Ty//6S5wzr8iSXy8MMFuAip8xhKxhmgznvrxgvDR3+zbNAwbeOh\n\toduZiTcbJf+UhxDE8+f14rQy/S8wC0+ojPVUkaHKLaTIg8ywY7WwJHP92Ip4437BL1\n\tGxiscMTQKwmpqWOMRP/Q/NU5/6H1dNNNt3GtoMSHuLzkLoDRTHWhFMflj4Pym8r6Hg\n\tdVLhCYLr4C88h+Ovk7pRauFN6JahW0xoaPaH2h6pEYSzzQA/FolUchSGuJK8nLxO7w\n\tURbbIuLAJMj1w==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1656665143;\n\tbh=4jssbuxUq5C1GVY59JXBlIIcwKau4KEUhfDWEvwAuHc=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=L5aYaAx9Q2T+ChYL315NXL8Ki06PTyUCKsKuV8NvT6amCKfsotOxlkByvXuYTF4/Y\n\tHu+rfMTo6TSe0XWzledVtEwygt1LMIEH+cDLJ5sobKfHT2XO9wEt0KSUBepymUDIGa\n\trFbcQgG6CyxuXN0ltmzRIZDOPmTqzOzwtpiWORH0="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"L5aYaAx9\"; dkim-atps=neutral","To":"libcamera-devel@lists.libcamera.org,\n\tDavid Plowman <david.plowman@raspberrypi.com>,\n\tKieran Bingham <kieran.bingham@ideasonboard.com>,\n\tLaurent Pinchart <laurent.pinchart@ideasonboard.com>,\n\tJacopo Mondi <jacopo@jmondi.org>","Date":"Fri,  1 Jul 2022 11:45:11 +0300","Message-Id":"<20220701084521.31831-8-tomi.valkeinen@ideasonboard.com>","X-Mailer":"git-send-email 2.34.1","In-Reply-To":"<20220701084521.31831-1-tomi.valkeinen@ideasonboard.com>","References":"<20220701084521.31831-1-tomi.valkeinen@ideasonboard.com>","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH v3 07/17] py: Set EFD_CLOEXEC on eventfd\n\tto avoid fd leaking","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>","From":"Tomi Valkeinen via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"Set EFD_CLOEXEC on eventfd to avoid fd leaking.\n\nSigned-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>\n---\n src/py/libcamera/py_camera_manager.cpp | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)","diff":"diff --git a/src/py/libcamera/py_camera_manager.cpp b/src/py/libcamera/py_camera_manager.cpp\nindex 51a890c8..3d422c9e 100644\n--- a/src/py/libcamera/py_camera_manager.cpp\n+++ b/src/py/libcamera/py_camera_manager.cpp\n@@ -22,7 +22,7 @@ PyCameraManager::PyCameraManager()\n \n \tcameraManager_ = std::make_unique<CameraManager>();\n \n-\tint fd = eventfd(0, 0);\n+\tint fd = eventfd(0, EFD_CLOEXEC);\n \tif (fd == -1)\n \t\tthrow std::system_error(errno, std::generic_category(),\n \t\t\t\t\t\"Failed to create eventfd\");\n","prefixes":["libcamera-devel","v3","07/17"]}