From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 79518 invoked by alias); 25 Oct 2017 21:00:42 -0000 Mailing-List: contact cygwin-apps-help@cygwin.com; run by ezmlm Precedence: bulk Sender: cygwin-apps-owner@cygwin.com List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Mail-Followup-To: cygwin-apps@cygwin.com Received: (qmail 78856 invoked by uid 89); 25 Oct 2017 21:00:41 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-100.6 required=5.0 tests=AWL,BAYES_00,GOOD_FROM_CORINNA_CYGWIN,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_BRBL_LASTEXT,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=H*R:D*cygwin.com X-HELO: drew.franken.de Received: from mail-n.franken.de (HELO drew.franken.de) (193.175.24.27) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 25 Oct 2017 21:00:39 +0000 Received: from aqua.hirmke.de (aquarius.franken.de [193.175.24.89]) (Authenticated sender: aquarius) by mail-n.franken.de (Postfix) with ESMTPSA id B1D987100A942 for ; Wed, 25 Oct 2017 23:00:36 +0200 (CEST) Received: from calimero.vinschen.de (calimero.vinschen.de [192.168.129.6]) by aqua.hirmke.de (Postfix) with ESMTP id 116C95E047D for ; Wed, 25 Oct 2017 23:00:36 +0200 (CEST) Received: by calimero.vinschen.de (Postfix, from userid 500) id 0063EA818DF; Wed, 25 Oct 2017 23:00:35 +0200 (CEST) Date: Wed, 25 Oct 2017 21:00:00 -0000 From: Corinna Vinschen To: cygwin-apps@cygwin.com Subject: Re: setup and colons in filenames Message-ID: <20171025210035.GA7980@calimero.vinschen.de> Reply-To: cygwin-apps@cygwin.com Mail-Followup-To: cygwin-apps@cygwin.com References: <20171025201650.GJ22429@calimero.vinschen.de> <4317ea35-5b64-1485-c970-210eac051a0f@dronecode.org.uk> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="IS0zKkzwUGydFO0o" Content-Disposition: inline In-Reply-To: <4317ea35-5b64-1485-c970-210eac051a0f@dronecode.org.uk> User-Agent: Mutt/1.9.1 (2017-09-22) X-SW-Source: 2017-10/txt/msg00128.txt.bz2 --IS0zKkzwUGydFO0o Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-length: 2517 On Oct 25 21:36, Jon Turney wrote: > On 25/10/2017 21:16, Corinna Vinschen wrote: > > On Oct 25 20:23, Jon Turney wrote: > > > On 25/10/2017 16:50, Ken Brown wrote: > > > > This is a followup to the thread started here: > > > >=20 > > > > =C2=A0 https://cygwin.com/ml/cygwin-patches/2017-q4/msg00012.html > > > >=20 > > > > Currently setup's parse_filename is not correctly parsing filenames= in > > > > /etc/setup/installed.db that contain colons, as explained in the ab= ove > > > > thread.=C2=A0 It would be easy to fix this by just ripping out the = 'base' > > > > function, except for the fact that parse_filename is called by > > > > ScanFindVisitor::visitFile. > > >=20 > > > Since older setup cannot correctly parse an installed.db containing > > > filenames like that, we should probably bump the installed.db version= at the > > > same time as fixing this. > > >=20 > > > > I don't know enough about WIN32_FIND_DATA to know whether the call = to > > > > 'base' is needed for that use of parse_filename.=C2=A0 If so, is it= safe to > > > > skip all colons in that setting, since we're dealing with Win32 > > > > filenames and they don't see the colons in Cygwin filenames? > > >=20 > > > Yeah, that's about as far as I got before giving up... > > >=20 > > > > Do we need two versions of parse_filename, one that calls base and = one > > > > that doesn't? > > >=20 > > > This might be the easiest solution :) > > >=20 > > > The other concern I had was if the filenames for the package archives= stored > > > in the download cache end up containing a ':', which I thought wasn't > > > allowed in windows filenames? > >=20 > > Colons in Cygwin filenames will have 0xf03a value in WIN32. The code to > > transpose special chars into the private use area at 0xf0XY is in setup, > > but I'm not sure if setup is really working correctly with archives > > containing a colon. > I think the package archives are stored using native Windows filenames, n= ot > cygwin filenames (i.e. file:// paths rather than cygfile:// paths), becau= se > the "Local Package Directory" is not necessarily under the cygwin root, so > I'm not sure that transformation applies. The transposition is handled in mklongpath, which is called in nt_fopen, or called manually in other callers of nt_wfopen to construct the long path. In theory, this should cover all bases... Corinna --=20 Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Maintainer cygwin AT cygwin DOT com Red Hat --IS0zKkzwUGydFO0o Content-Type: application/pgp-signature; name="signature.asc" Content-length: 819 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJZ8PtzAAoJEPU2Bp2uRE+g1oUP/0fm6d7smOWWbOI7Oz8hBwbV KEDCNY3XCts5n3DVmn5vWOkYGhC2mxHuSjZbw02q0nSpkKskasnF2AE2AiOBsvfG vSvGOrqUSnnd1AxPTG9znQnzuiLqf7se+zGr/3TThw+FfQap1Ge59/ziF+88/GyV Z4QXPPOLXFRrZdNoMCSXupa0Jv7gKZDgSxRUFeFpi/0vjWIi8a6q+MHG1GKSC4zi AWljHduGLSQhKbzaV9iIA+NPxmdSNXB6qhknxP7Rf34nD9FpQwzpwFZ/PF8Zj2TP K6xGgIDB+Vu+w3R4GI4dFDQbq2YScAgumk2iwwZ9ZPXsecAb6jqcFKd0eV9Byg50 HAvJf3KI49ur2LyTFWy4EAAcSaCPvxt6LNKYR9ie+ERHDaEvBNDNSS/ofl4oBmPH aVJO7MFocFnq97CVfbccrQFIMz1Tqwbd9Z8W9GcZ2B1kSuLVLk+k9UMhR7XAHNJr 2X+OCwfhAIVc1LnDyNUBTJ+CARjUz10Xltn9LTI/jgVCL/nET01ca1JYVGGbRMNc yi8db7EgEE0F2ZgZO5STD3s40qB2yKziFL0Sc2AWcyCoUK2imvw69wWlnUoucawT v4b7W9cyjyTzYBBSWqxDidE+zEkcWkMtR5MftC3TqGjx7m6E733rauEt4wgIrdAJ Xl0lPNkO7w1riBhg++uD =RVhz -----END PGP SIGNATURE----- --IS0zKkzwUGydFO0o--