Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rZT54-004VSe-Hn for pgsql-hackers@arkaria.postgresql.org; Mon, 12 Feb 2024 09:58:31 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rZT53-008RyZ-Ma for pgsql-hackers@arkaria.postgresql.org; Mon, 12 Feb 2024 09:58:29 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rZT53-008RyP-DE for pgsql-hackers@lists.postgresql.org; Mon, 12 Feb 2024 09:58:29 +0000 Received: from meesny.iki.fi ([2001:67c:2b0:1c1::201]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rZT50-006n20-Qv for pgsql-hackers@postgresql.org; Mon, 12 Feb 2024 09:58:28 +0000 Received: from [192.168.1.115] (dsl-hkibng22-54f8db-125.dhcp.inet.fi [84.248.219.125]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: hlinnaka) by meesny.iki.fi (Postfix) with ESMTPSA id 4TYKf83j5JzyNC; Mon, 12 Feb 2024 11:58:24 +0200 (EET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iki.fi; s=meesny; t=1707731905; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=1lthdKo9lCKfLiNK11yD1GU1Czp/G69YMpsH+qW6n8U=; b=PF/FErkyO8EmBoZJ9rqcZ+XpAIxRVjYVKxcu0mc7O1TVbMTkGHhVTNuGuzN/X09ZO4kRIq UbCVqipfH0jSHJVjwRJssy/qLKVGHi8Kh1sWxAipKpiRlAL+gSRSI2B9wLYd+qOhoF1yKe UInFAsDQpgSt5FmEg9BaoO7owwEryXc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=iki.fi; s=meesny; t=1707731905; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=1lthdKo9lCKfLiNK11yD1GU1Czp/G69YMpsH+qW6n8U=; b=nGrPNAVmPVvszG4qJvbl7q4lWTw9ilJ4uBbm8IkixG5Kjm9M3j3nmzKcONOcK6SLwn91VQ ysTQBiNkLIi5UV1LY4jnwnP9GGjOIm/U+ixsiN7IzW9Rm0gEIrfcbVjKUICSdFSeQ6+Rne 4NLtQmS0GzpN2HfM0gChjVnumilIa+s= ARC-Seal: i=1; s=meesny; d=iki.fi; t=1707731905; a=rsa-sha256; cv=none; b=Hp2x9q0VAl8ymoxNU3/6fHMTqoC6txtsXDMyyc8mZjM2P7hF+0K71CbYagIrTN2NDAZu/w awh3r2CTllkEkuJ6DzBZjeYkUeb3x1yabhXY9mZA/8OfiCHqR0TISoxX4Oncs6iUQF4nlt Lb0RCdIkWZCjjchcGqkPhmZiP73IL4I= ARC-Authentication-Results: i=1; ORIGINATING; auth=pass smtp.auth=hlinnaka smtp.mailfrom=hlinnaka@iki.fi Message-ID: <87d1ba81-0fe8-4ef6-912b-afdc751beae2@iki.fi> Date: Mon, 12 Feb 2024 11:58:24 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Remove WIN32 conditional compilation from win32common.c Content-Language: en-US To: Tristan Partin , pgsql-hackers References: From: Heikki Linnakangas In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 05/12/2023 20:37, Tristan Partin wrote: > The file is only referenced in Meson and MSVC scripts from what I can > tell, and the Meson reference is protected by a Windows check. There are a bunch of files like win32common.c: $ ls src/port/win32*.c src/port/win32common.c src/port/win32dlopen.c src/port/win32env.c src/port/win32error.c src/port/win32fdatasync.c src/port/win32fseek.c src/port/win32gai_strerror.c src/port/win32getrusage.c src/port/win32gettimeofday.c src/port/win32link.c src/port/win32ntdll.c src/port/win32pread.c src/port/win32pwrite.c src/port/win32security.c src/port/win32setlocale.c src/port/win32stat.c Of these, win32stat.c and win32fseek.c also contain "#ifdef WIN32", but others don't. So I concur that the most common pattern in these files is to not use #ifdef WIN32, and +1 for making them consistent. I removed those from win32stat.c and win32fseek.c, too, and committed. Thanks! -- Heikki Linnakangas Neon (https://neon.tech)