Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp4553389yba; Tue, 7 May 2019 21:39:43 -0700 (PDT) X-Google-Smtp-Source: APXvYqziA+Z8rlITfmH/SPweZ31ckhd9Bv8pgm9nl4IY47WMMpsLvp+r1bp+0QQln1EyA91aAzUp X-Received: by 2002:a63:560d:: with SMTP id k13mr44058310pgb.124.1557290383321; Tue, 07 May 2019 21:39:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557290383; cv=none; d=google.com; s=arc-20160816; b=0Rq0Hp3iHLzM4vA1SNPydLJXA8aFlj+Lz3348laMK5nQT5Yt9V+20Zn8fdNec24HBZ PI3BtIVzoVVpef4i5l9ssBkXGx+qxMvgCjNie2XjZ3iACRs8uUXLOLWMUKfeQ5fL+Xhf LVwAhwq/7JkZB/8aUXMKjMq0GVix7p6We0uQR6FN6rne5SX3vfZrJ83ZBIJXIOIhXiD+ +2DX5jwW0fX7Dxw3hY78ba3qL2M/mlCJt4PjfKzVi2Ev+b78FX5rRGQ+qzlL/49hAshl zRD3YQc4JMyCbVfMLZ7G2epmA5MmxNkgQ+2o/92faYhfueO8XUMsJozaXMG3jB7aU+Ll CHuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:mail-followup-to:message-id:subject:cc:to:from:date :dkim-signature; bh=7H3CU9ljq4FRqsQ2m2Y9RjLx9vQcNyr/LeXQezkTk1I=; b=NTAxFQn42WcxShsqxr1Q1vXbgDSsMTk8rywzpOwh2cksKRFgoWRqnqaXix024iTq+5 8yuRtXLlQxYg90A6qttk0udvf/M79g/oMCUEYOHLavgQTKx7bRiv7uWCwkEi4Usm8UY0 xZkMEHhnn3gsenuaueOVZLFQvnGtfWaZ5RoAwnJTofONaw3WZKdpmwR3aW+M0rVcjG4i ts10ZJpJ1lC7+uONVfeah4B9zLc/3DHOO5HsFw9KFAoueD0zMU68G9EgxWFuJ7EZ4ApY Fd05wxZ+QgtWE9jJzdcM5Ivx1QnOlNgP7PSYE7eZdldqyvgP01PPpPOLlk+qrhfDaYBF fM0Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@silvair-com.20150623.gappssmtp.com header.s=20150623 header.b=jS52phGL; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p7si13151344pfb.213.2019.05.07.21.39.10; Tue, 07 May 2019 21:39:43 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@silvair-com.20150623.gappssmtp.com header.s=20150623 header.b=jS52phGL; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725866AbfEHEjG (ORCPT + 99 others); Wed, 8 May 2019 00:39:06 -0400 Received: from mail-lf1-f66.google.com ([209.85.167.66]:35359 "EHLO mail-lf1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726109AbfEHEjG (ORCPT ); Wed, 8 May 2019 00:39:06 -0400 Received: by mail-lf1-f66.google.com with SMTP id j20so13505989lfh.2 for ; Tue, 07 May 2019 21:39:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=silvair-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:mail-followup-to:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=7H3CU9ljq4FRqsQ2m2Y9RjLx9vQcNyr/LeXQezkTk1I=; b=jS52phGLr/faCDSu39ThhZc5tfP5K47t6DGj7Ta9MKlfg0r21S1+fbnp25W8KOCim4 1mcTOjaiirIRwyw3tevIrkp2Lwd1R9OdTIwE/yfmBzvHIMHsaV9J4s8Tgasn7EJmTIIx 2gKCPXwlqbd/1nhHB/n0AZ1CdQOtvQAMbweGpTWDsTWC75ot7/OZFSR3sLhvQGjy1zJi pT4ZHcLW/eUPrCO1cocn0FxheUZ8kwBQgefq5svrPqH6tv0uoLTFbMhhkeFvIZYmXydt NeXqFeFHzLFvHbHJwA4X00ZwSltTh7Iu40M5ZQMzWXj0mYpKAD9fuac9VGtEyngXSWh9 yrNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id :mail-followup-to:references:mime-version:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=7H3CU9ljq4FRqsQ2m2Y9RjLx9vQcNyr/LeXQezkTk1I=; b=IxUHQJTQ3vmWb3VI4vt6jk51LzwWokdbo5ilwrbSCPkvfEu/TxdlYltt+AXHjNekmT YAQW0lp4/CkhOdoFyPZvZSR97ZqCCwhOl6i2F0oMo0Mvi6GZ0uJC41qoGNauDbzJrgpG Nga9Qe1GHSjSUMu+XYtN8YXAu2nhDq3EwtO6rvMxS34sn4d1ZfxT4YSu6z1Sc83wnPI7 kAcSphwRFmaV2xqZ7E0WZMwnzcKVVrQVVNPQiqmZwki9Kr2Kx8MtlFb6u5XyMPl2VVUE GWxpw/cYnQajd9GbFP7uaC9GV4tzEtWktEHloeWOsn5+F/CItfaWu/ZccRLd6IUINRbE hHtg== X-Gm-Message-State: APjAAAV9d5AO2RM/6D8HBEA9h5EIaBfsjbU3OnMo+mb1C+kzdgmlwINP v2vbBiXr206JVFFrCp+h+Arfbg== X-Received: by 2002:a19:c60f:: with SMTP id w15mr7459035lff.61.1557290344600; Tue, 07 May 2019 21:39:04 -0700 (PDT) Received: from kynes (apn-31-2-19-253.dynamic.gprs.plus.pl. [31.2.19.253]) by smtp.gmail.com with ESMTPSA id r9sm417055ljb.79.2019.05.07.21.39.02 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 07 May 2019 21:39:03 -0700 (PDT) Date: Wed, 8 May 2019 06:39:01 +0200 From: "michal.lowas-rzechonek@silvair.com" To: Denis Kenzior Cc: "Gix, Brian" , "linux-bluetooth@vger.kernel.org" , "Stotland, Inga" Subject: Re: [PATCH BlueZ v2] mesh: Use node uuids as storage directory names Message-ID: <20190508043901.bcueazjay3nm6cya@kynes> Mail-Followup-To: Denis Kenzior , "Gix, Brian" , "linux-bluetooth@vger.kernel.org" , "Stotland, Inga" References: <20190507071340.20675-1-michal.lowas-rzechonek@silvair.com> <1557261666.31289.11.camel@intel.com> <18e096c6-3b22-0096-5cb2-bef7264dbefe@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <18e096c6-3b22-0096-5cb2-bef7264dbefe@gmail.com> User-Agent: NeoMutt/20180716 Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Hi Denis, Brian, On 05/07, Denis Kenzior wrote: > > > + if (asprintf(&cfg, "%s/%s/node.json", dir_name, > > > + entry->d_name) < 0) > > > + continue; > > > > With ELL, we do not use asprintf. Every dynamic allocation must map > > back to l_malloc, which performs an abort() if a memory allocation > > fails. So this should be re-coded as a malloc of the desired size, > > and then use snprintf, using the malloc'd length as N. > > ...or use l_strdup_printf. Which is actually asprintf underneath... > ;) Will do, thanks for the tip! Incidentally, are you aware why 'main' bluez aims to drop glib? cheers -- Michał Lowas-Rzechonek Silvair http://silvair.com Jasnogórska 44, 31-358 Krakow, POLAND