From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59507) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d2h1d-0001nk-Qf for qemu-devel@nongnu.org; Mon, 24 Apr 2017 12:39:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d2h1a-0004zi-NW for qemu-devel@nongnu.org; Mon, 24 Apr 2017 12:39:45 -0400 Received: from mx1.redhat.com ([209.132.183.28]:32945) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1d2h1a-0004zd-HR for qemu-devel@nongnu.org; Mon, 24 Apr 2017 12:39:42 -0400 Date: Mon, 24 Apr 2017 17:39:36 +0100 From: "Daniel P. Berrange" Message-ID: <20170424163936.GE7705@redhat.com> Reply-To: "Daniel P. Berrange" References: <20170424125016.GM20809@redhat.com> <20170424133624.GP20809@redhat.com> <20170424135749.GR20809@redhat.com> <20170424154117.GB7705@redhat.com> <20170424155255.GD7705@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Subject: Re: [Qemu-devel] error: qcrypto_random_bytes() tried to read from /dev/[u]random, even on windows List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Geert Martin Ijewski Cc: Peter Maydell , QEMU Developers On Mon, Apr 24, 2017 at 06:33:26PM +0200, Geert Martin Ijewski wrote: > > We can have the existing qcrypto_init() call a qcrypto_random_init() > > method to do the one-time initialization task, since that's already > > required to run early in order to initialize gnutls when we use it. > > Wouldn't it make sense to also move the unix initalization to that function? Yep, we can do that. > And what about deinitalization? Though because that handle needs to stay > valid throughout the whole lifetime of QEMU anyway, that probably can be > ignored and taken care of by the OS Correct, there's no need for any de-init if we have a global handle, as it is needed until QEMU exits. Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|