From nobody Mon Feb 9 07:56:23 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=reject dis=none) header.from=comstyle.com ARC-Seal: i=1; a=rsa-sha256; t=1613978988; cv=none; d=zohomail.com; s=zohoarc; b=KX3f3mOS0Qt69rJapXeDKvyhXD4KhYoX4tlgw+lZbRdV3xQVjlW9Rfb/vb/wjJv/hwkYy/sTm1Ky2i8MrXdN0RO0XM0CwZ69xYPKre72LANH/+GiMljnnFNoojTry+fYBv6dImY9gOLdsH9V21EOiiNsMB/8PghW1danNIHG8TU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1613978988; h=Content-Type:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=Pv4pQ8XJi0bSTBe6shMG2SLBm4ANFhLfFIer31YVzu0=; b=ag+3BIvqekH7GIyiqZpDigUF4Qtez5u1qSKMV1Kmz7giXObOj+1f18//9bzVAVElUVPmO3KU+y9qfmmgfm88CgwxKEL0pOIRv/JReze9MgPvQEf9JhuHoUnzqTH7zYjhnEePa+oDhHWxSl27WWjSQ46cQ3FRpUHDyEBc2FHLM1M= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=reject dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1613978988396570.1079985166499; Sun, 21 Feb 2021 23:29:48 -0800 (PST) Received: from localhost ([::1]:40270 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lE5f8-0007Jt-FY for importer@patchew.org; Mon, 22 Feb 2021 02:29:46 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:35492) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lE5dl-0006qB-2P for qemu-devel@nongnu.org; Mon, 22 Feb 2021 02:28:21 -0500 Received: from speedy.comstyle.com ([2607:f938:3000:8::2]:9126 helo=mail.comstyle.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1lE5di-0004VA-Fd for qemu-devel@nongnu.org; Mon, 22 Feb 2021 02:28:20 -0500 Received: from mail.comstyle.com (localhost [127.0.0.1]) by mail.comstyle.com (Postfix) with ESMTP id 4DkYjh1rZtz8PbN for ; Mon, 22 Feb 2021 02:30:00 -0500 (EST) Received: from humpty.home.comstyle.com (bras-base-toroon2719w-grc-43-174-88-243-61.dsl.bell.ca [174.88.243.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: brad) by mail.comstyle.com (Postfix) with ESMTPSA id 4DkYjh1B1yz8PbK for ; Mon, 22 Feb 2021 02:30:00 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=comstyle.com; h=date:from :to:subject:message-id:mime-version:content-type; s=default; bh= G/WzEknvjJH14+e3t0izjdKLLK4=; b=jeSbRvjeMExjg8mlSk8F0cbqSww+c6YG 8rnpi9CbTJAb3OAWmBNkow/veIANS9e37nu84ZANtn9A6l4uJpKVsDWtuhJHa4VZ GSxgxZ1e38pkWqiO/ojT8Po/lVQppc4kv5BoA+tSgCKb5EGXOfmL1ZnEkKGniNRM fxr5kHNiY+Y= DomainKey-Signature: a=rsa-sha1; c=nofws; d=comstyle.com; h=date:from:to :subject:message-id:mime-version:content-type; q=dns; s=default; b= TG50spB00PJShaHnIq+sFg9fyvKtGde2DRqY8fnD5GiE/gfXl2yEa9xba2pCliPH ioZ9jZ227VTPbye1/mT+9a7ysz5c9mVHMawTq7Hx3ZJDGGW1RnDbRMhrkC7zyx88 SzWK/e9NOzPRE4gncuBIM57yebv7dw9ANBGXmxSO81I= Date: Mon, 22 Feb 2021 02:28:02 -0500 From: Brad Smith To: qemu-devel@nongnu.org Subject: [PATCH] migration: Remove time_t cast for OpenBSD Message-ID: MIME-Version: 1.0 Content-Disposition: inline Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2607:f938:3000:8::2; envelope-from=brad@comstyle.com; helo=mail.comstyle.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @comstyle.com) Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" OpenBSD has supported 64-bit time_t across all archs since 5.5 released in = 2014. Remove a time_t cast that is no longer necessary. Signed-off-by: Brad Smith diff --git a/migration/savevm.c b/migration/savevm.c index 52e2d72e4b..9557f85ba9 100644 Reviewed-by: Thomas Huth --- a/migration/savevm.c +++ b/migration/savevm.c @@ -2849,8 +2849,7 @@ bool save_snapshot(const char *name, bool overwrite, = const char *vmstate, if (name) { pstrcpy(sn->name, sizeof(sn->name), name); } else { - /* cast below needed for OpenBSD where tv_sec is still 'long' */ - localtime_r((const time_t *)&tv.tv_sec, &tm); + localtime_r(&tv.tv_sec, &tm); strftime(sn->name, sizeof(sn->name), "vm-%Y%m%d%H%M%S", &tm); } =20