From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:34403) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YIHcd-0001G6-Cq for qemu-devel@nongnu.org; Mon, 02 Feb 2015 09:05:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YIHcZ-0000Rr-BK for qemu-devel@nongnu.org; Mon, 02 Feb 2015 09:05:03 -0500 Received: from mail-pa0-x236.google.com ([2607:f8b0:400e:c03::236]:59386) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YIHcZ-0000Rk-4H for qemu-devel@nongnu.org; Mon, 02 Feb 2015 09:04:59 -0500 Received: by mail-pa0-f54.google.com with SMTP id eu11so82757382pac.13 for ; Mon, 02 Feb 2015 06:04:58 -0800 (PST) Date: Mon, 02 Feb 2015 23:04:52 +0900 Message-ID: <87y4og76kb.wl%mitake.hitoshi@gmail.com> From: Hitoshi Mitake In-Reply-To: <20150202113600.GA9478@noname.redhat.com> References: <1421917694-6824-1-git-send-email-mitake.hitoshi@lab.ntt.co.jp> <1421917694-6824-2-git-send-email-mitake.hitoshi@lab.ntt.co.jp> <87y4ogproy.wl%mitake.hitoshi@lab.ntt.co.jp> <20150202113600.GA9478@noname.redhat.com> MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Subject: Re: [Qemu-devel] [PATCH v2 1/4] qemu-io: initialize progname with error_set_progname() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: Hitoshi Mitake , Stefan Hajnoczi , qemu-devel@nongnu.org, mitake.hitoshi@gmail.com, Markus Armbruster At Mon, 2 Feb 2015 12:36:00 +0100, Kevin Wolf wrote: > > Am 02.02.2015 um 10:51 hat Hitoshi Mitake geschrieben: > > At Thu, 22 Jan 2015 18:08:11 +0900, > > Hitoshi Mitake wrote: > > > > > > Calling error_get_progname() in the context of qemu-io can cause > > > segmentation fault because qemu-io doesn't initialize its progname > > > with error_set_progname(). This patch adds the initialization. > > > > > > Currently, the missing call of error_set_progname() doesn't cause any > > > problems because qemu-io doesn't use error_get_progname(). This patch > > > is a proactive action. > > > > > > Cc: Kevin Wolf > > > Cc: Stefan Hajnoczi > > > Cc: Markus Armbruster > > > Signed-off-by: Hitoshi Mitake > > > --- > > > qemu-io.c | 1 + > > > 1 file changed, 1 insertion(+) > > > > Hi Kevin, Stefan, could you pick this patch? sheepdog driver has a > > pending patch [1] which depends on it. I believe at least qemu-io > > should call error_set_progname() because block drivers can use the > > qemu-error infrastructure. > > So are you planning to get the individual patches merged on their own > instead of the whole series as one? I thought this patchset can be proactive fix. So I'm separating the patch for sheepdog driver from this one. > > > [1] https://github.com/sheepdog/qemu/commit/a95c35e606a2a189e7dbaf645277c5c306b01e4b > > That patch looks wrong. Nobody guarantees that qemu-io is really called > qemu-io. The user can name their binaries as they want and create > symlinks with any name, and indeed names for qemu-img used by some > distributions include 'qemu-img-kvm' and 'kvm-img'. You need to find a > different way than checking binary file names. I couldn't consider about the case, thanks for pointing! I'll seek other method for distinguishing binary files. Thanks, Hitoshi > > Kevin