Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fgcnB-0005rM-66 for pgsql-hackers@arkaria.postgresql.org; Fri, 20 Jul 2018 21:18:25 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1fgcn9-00071I-Aw for pgsql-hackers@arkaria.postgresql.org; Fri, 20 Jul 2018 21:18:23 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fgcn9-00071A-0L for pgsql-hackers@lists.postgresql.org; Fri, 20 Jul 2018 21:18:23 +0000 Received: from www4.webmail.pair.com ([66.39.3.58]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fgcn1-0004Xf-0j for pgsql-hackers@postgresql.org; Fri, 20 Jul 2018 21:18:21 +0000 Received: by www4.webmail.pair.com (Postfix, from userid 65534) id 6DF89B400B1; Fri, 20 Jul 2018 17:18:13 -0400 (EDT) Received: from 81.173.182.225 ([81.173.182.225]) (SquirrelMail authenticated user te_123@bloodgate.com) by sm.webmail.pair.com with HTTP; Fri, 20 Jul 2018 17:18:13 -0400 Message-ID: In-Reply-To: <20180720175508.07776219@fafnir.local.vm> References: <20180720153820.69e9ae6c@fafnir.local.vm> <17833.1532096747@sss.pgh.pa.us> <20180720175508.07776219@fafnir.local.vm> Date: Fri, 20 Jul 2018 17:18:13 -0400 Subject: Re: Non-portable shell code in pg_upgrade tap tests From: "Tels" To: "Victor Wagner" Cc: "Tom Lane" , "pgsql-hackers" User-Agent: SquirrelMail/1.4.23 [SVN] MIME-Version: 1.0 Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Moin, On Fri, July 20, 2018 10:55 am, Victor Wagner wrote: > On Fri, 20 Jul 2018 10:25:47 -0400 > Tom Lane wrote: > >> Victor Wagner writes: >> > I've discovered that in the branch REL_11_STABLE there is shell >> > script src/bin/pg_upgrade/test.sh which doesn't work under Solaris >> > 10. (it uses $(command) syntax with is not compatible with original >> > Solaris /bin/sh) > >> >> Please send a patch. Most of us do not have access to old shells > > Here it goes. Previous letter was written before fixed tests were > completed, because this old machine is slow. + *) if [ `find ${PGDATA} -type f ! -perm 640 | wc -l` -ne 0 ]; then Shouldn't ${PGDATA} in the above as argument to find be quoted, otherwise the shell would get confused if it contains spaces or other special characters? Regards, Tels