Received: from eggs.gnu.org ([2001:4830:134:3::10]:40896) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eBl3X-0007h7-8E for qemu-devel@nongnu.org; Mon, 06 Nov 2017 12:19:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eBl3T-0004qN-Tb for qemu-devel@nongnu.org; Mon, 06 Nov 2017 12:19:27 -0500 Received: from mout.gmx.net ([212.227.17.21]:58687) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eBl3T-0004pn-JA for qemu-devel@nongnu.org; Mon, 06 Nov 2017 12:19:23 -0500 References: <20171106005656.GC84093@humpty.home.comstyle.com> From: Kamil Rytarowski Message-ID: <5ed0a508-e22a-5d59-c826-54fa17afcf20@gmx.com> Date: Mon, 6 Nov 2017 18:21:45 +0100 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="f66bIae8xG55N6311ACtsgXxwNVE5sqrV" Subject: Re: [Qemu-devel] [PATCH] osdep: Deal with TIME_MAX and OpenBSD 64-bit time_t List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell , Brad Smith Cc: QEMU Developers This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --f66bIae8xG55N6311ACtsgXxwNVE5sqrV From: Kamil Rytarowski To: Peter Maydell , Brad Smith Cc: QEMU Developers Message-ID: <5ed0a508-e22a-5d59-c826-54fa17afcf20@gmx.com> Subject: Re: [Qemu-devel] [PATCH] osdep: Deal with TIME_MAX and OpenBSD 64-bit time_t References: <20171106005656.GC84093@humpty.home.comstyle.com> In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 06.11.2017 11:51, Peter Maydell wrote: > On 6 November 2017 at 00:56, Brad Smith wrote: >> Define TIME_MAX to LLONG_MAX for OpenBSD since OpenBSD uses 64-bit tim= e_t. >> >> Signed-off-by: Brad Smith >> >> >> diff --git a/include/qemu/osdep.h b/include/qemu/osdep.h >> index 6855b94bbf..824714049b 100644 >> --- a/include/qemu/osdep.h >> +++ b/include/qemu/osdep.h >> @@ -132,8 +132,12 @@ extern int daemon(int, int); >> #define ESHUTDOWN 4099 >> #endif >> #ifndef TIME_MAX >> +#ifdef __OpenBSD__ >> +#define TIME_MAX LLONG_MAX >> +#else >> #define TIME_MAX LONG_MAX >> #endif >> +#endif >=20 > I'm not really a fan of adding new OS-specific #ifdefs -- > what if one of the other BSDs uses or switches to 64-bit > time_t for 32-bit platforms? Is there some way we can detect > this generically at compile time (possibly in configure) ? >=20 NetBSD 32-bit ports switched to 64-bit in 2009. There are no longer supported releases with 32-bit time_t. > thanks > -- PMM >=20 --f66bIae8xG55N6311ACtsgXxwNVE5sqrV Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJaAJovAAoJEEuzCOmwLnZsxQYQAKaQNqy1t6O0hRYrdpYV4xKl I65Ko4dYtUae5upUdVM62O7r1WNf/3s6+vPjpw0CVB5HYARizgYrh9SJX9p+mKxF P2+IFtGQSTJ1CbwCWp5Drjm+nnKF2sRjKoU0laAJuRslYpsWpaCjwgC4KLv+H7vj HYvYag5ZcaqhYicavKvYfBiJPqYYSJtiMDT+6r+G3hU0GI9SqYaOoxaly2GQ452h oDx31BQdmRXhIcPXytSz7wguIKOEbYguHwTgysvkabiBg8BN7ZIZz5oub4R7RxET 1Fdl4+T8HZM0F0ApgTBRY4cVMfS1HeucZZNIy9d7EkrbAYHNCFWPPZzwBaJSZacT NpeVcY0yPD9VLXUfZZFzn376DvU57q/Ak6zs2Jkd0rr3ef9w/+enp4nv7oR/S7sT AqCHevOub3Q4DsfAgwvfp9HPNrri+8arcowUgF1jhH20lCebqFIR85zrwr/3wCnx yF7GtHOB9Qc7EHKgKbMZIF84spfuIo4B1MTR3vxZDzYL7A7XCV+r6s1XDPw1fn9S 6IxvkWO41XWJ9fW2fdvMT5AVapnjlCPupkaRAL1zVvRKLTSBt4/22/ipYtQilC/0 qznV85VKDAkyAbcaH3LeDT4nbK/AIsjSRfJVkYPKkwyS8JJ4iOlLizb5A8mzWDAH b7b+5lUDMPE9z8+A72EF =JIID -----END PGP SIGNATURE----- --f66bIae8xG55N6311ACtsgXxwNVE5sqrV--