Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1l30XA-0002hG-Fs for pgsql-bugs@arkaria.postgresql.org; Fri, 22 Jan 2021 17:47:44 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1l30X8-0004PL-GI for pgsql-bugs@arkaria.postgresql.org; Fri, 22 Jan 2021 17:47:42 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1l30X8-0004PE-AF for pgsql-bugs@lists.postgresql.org; Fri, 22 Jan 2021 17:47:42 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1l30X5-0001e2-Ct for pgsql-bugs@lists.postgresql.org; Fri, 22 Jan 2021 17:47:41 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 10MHlVda1168202; Fri, 22 Jan 2021 12:47:31 -0500 From: Tom Lane To: Andres Freund cc: Ricardo Ungureanu , kimon.krenz@part9.com, pgsql-bugs@lists.postgresql.org Subject: Re: BUG #16827: macOS interrupted syscall leads to a crash In-reply-to: <20210122173535.5zzud4b6ffk4mym6@alap3.anarazel.de> References: <16827-7606aeb21d38c228@postgresql.org> <20210115210548.zfbnulfeanmffmet@alap3.anarazel.de> <20210122173535.5zzud4b6ffk4mym6@alap3.anarazel.de> Comments: In-reply-to Andres Freund message dated "Fri, 22 Jan 2021 09:35:35 -0800" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1168200.1611337651.1@sss.pgh.pa.us> Date: Fri, 22 Jan 2021 12:47:31 -0500 Message-ID: <1168201.1611337651@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Andres Freund writes: > Tom, all, this seems like a serious problem likely to become more > widespread. I don't really know how we can reasonably address this > short-term, adding EINTR handling to all the places that don't yet have > it (and ensuring that it stays that way) seems like it's a lot to backport. The only idea that comes to mind is to invent a wrapper for open (and other affected syscalls) that adds a loop-on-EINTR. Ugly, and it would not fix third-party extensions until they're recompiled. My inclination is to regard this as something that's Apple's problem, at least for now. Perhaps they'll realize what a disaster it is. (OTOH, they've proven pretty mulish on making SIP usable...) regards, tom lane