delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2015/10/23/05:20:34

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:date:from:to:subject:message-id:reply-to
:references:mime-version:content-type:in-reply-to; q=dns; s=
default; b=bSqMGwbswYDFSevKaxCygRG+nW4Ji8Dx/ioigYnl1lqAnXWOBNOiC
lEPqSuTtmVvalHF50Xgy74NanApDn9tMHj5T/mtp5UXnDC7RViqRc97EGypew4Vr
hEaLBSrEtxr9ToAjxsbuskKoVstGdOj8BpMgKhRUNBLR7zU2I5/Scg=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:date:from:to:subject:message-id:reply-to
:references:mime-version:content-type:in-reply-to; s=default;
bh=KKQkZOw5FzcQx5Z3mb7dYDfYUFI=; b=nCKi457CNbRQNjyWIsZ8Nk7U+4Ht
hqe6zZSqtIqykDlQqhxJ2yqQlgAbnDwKmG2GLGHA7DAk/6zZm/+hz/fM0aZi1MUf
Q9hgi1+LmVH9bRljA4l5lUckIcnDJgX7ukFPfcHY1lJXm/zB87tIKORnIK7t/W4T
asMdV2uWQv8ASXU=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-4.1 required=5.0 tests=AWL,BAYES_50,KAM_LAZY_DOMAIN_SECURITY autolearn=no version=3.3.2
X-HELO: calimero.vinschen.de
Date: Fri, 23 Oct 2015 11:20:07 +0200
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: Error accessing mapped drive >2TB?
Message-ID: <20151023092007.GF5319@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <CA+2x6-L_pqdN6PHE0c15hcmrmB66Z75Hz95cH+dbcn4yXuVZNg AT mail DOT gmail DOT com> <712A87EA-64C7-4033-BE7F-39C8C8D527EB AT etr-usa DOT com> <20151021100328 DOT GL5319 AT calimero DOT vinschen DOT de> <CB8461F5-FB0E-44D8-81BB-B52DD02AD400 AT etr-usa DOT com> <20151021162254 DOT GC19868 AT calimero DOT vinschen DOT de> <169BF9F6-FF26-4073-9CC4-786882EFBAE9 AT etr-usa DOT com> <20151022083446 DOT GW5319 AT calimero DOT vinschen DOT de> <B8DBF0B5-51A9-4833-92D5-CA9E08B27DEC AT etr-usa DOT com>
MIME-Version: 1.0
In-Reply-To: <B8DBF0B5-51A9-4833-92D5-CA9E08B27DEC@etr-usa.com>
User-Agent: Mutt/1.5.23 (2014-03-12)

--4dbYIUm7Fhfg+fSv
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Oct 22 12:34, Warren Young wrote:
> On Oct 22, 2015, at 2:34 AM, Corinna Vinschen wrote:
> >=20
> > On Oct 21 11:26, Warren Young wrote:
> >> On Oct 21, 2015, at 10:22 AM, Corinna Vinschen wrote:
> >>>=20
> >>> On Oct 21 09:52, Warren Young wrote:
> >>>>=20
> >>>> I mean, I know how to snag a stream of SMB packets with Wireshark, b=
ut
> >>>> I don=E2=80=99t know what I=E2=80=99d be looking for in the dump.
> >>>=20
> >>> Me neither, the Samba guys might be able to help there, perhaps.
> >>=20
> >> Apple hasn=E2=80=99t shipped Samba as part of OS X since 10.6, quite a=
 few
> >> years ago now.  In 10.7, they switched to an internally-developed SMB
> >> server.
> >=20
> > Yes, but the SMB guys can recite the wire format of SMB asleep, probabl=
y.
>=20
> Why would the Samba project=E2=80=99s wizards be motivated to help debug a
> closed-source piece of software they didn=E2=80=99t write?

No idea, it was just a suggestion.

> If anything, I=E2=80=99d expect them to give Apple the finger for booting
> Samba out of OS X in the first place.
>=20
> > There's also
> > https://msdn.microsoft.com/en-us/library/windows/desktop/aa365233%28v=
=3Dvs.85%29.aspx
>=20
> Now we=E2=80=99re talking about *my* motivation, which has only been to t=
est
> the original report and the fix.

Well, it was *you* asking "How could we prove that the problem is the
Apple SMB server?"  I was just trying to help.  If that's not desired,
I don't have to.

> >>> HANDLE handle =3D CreateFile ("P:\\", ...);
> >>=20
> >> I guess I=E2=80=99m not seeing what values to pass to CreateFile()
> >=20
> > Opening a directory requires to use the FILE_FLAG_BACKUP_SEMANTICS
> > flag.
>=20
> Yes, silly me for not guessing that Windows requires that I tell it I
> am about to do a backup before I attempt to open a directory for
> reading.  What was so wrong about the design of opendir() that MS had
> to reinvent it this way?

Think DOS/early Windows.  CreateFile was not meant to open directories
to perform a directory search and you couldn't do that on Windows 9x
anyway.  On NT the functions to do that were hidden in the NT API
originally.  Directory searches were meant to be performed using
FindFirstFile, etc., just as on 9x.

> I also had to fix an error in your original code: GetFileAttributes()
> takes a path string, not a HANDLE.

Oh, sorry, that should have been GetFileInformationByHandle.  It does
not help to call GetFileAttributes with a path since that obviously
won't use the previously opened handle.

> > Oh and, you have to use the FILE_FLAG_OPEN_REPARSE_POINT flag, of
> > course.
>=20
> Adding that doesn=E2=80=99t affect the error I get from the program, so I=
 left
> it out in the Pastebin version.

Without this flag the testcase won't do what Cygwin does.


Corinna

--=20
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

--4dbYIUm7Fhfg+fSv
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJWKfvHAAoJEPU2Bp2uRE+gj30QAJx9gTExd2yPs0nct/gnqvyh
xuuLoNmX4KOoS68ertDT8RWhIiqG5m9rtYPtXd5X0kt2B7HUdm+m3UjroxN0t7Ca
ikbMBCfREUpGUSjUP7422WiYM+CpYipIpzRSyoQpyEW0k+v83EvdwEqKWF27+fXZ
pts/6ObTwhpR4V7cLy+Mi8ikC/zHZ2bUvuuH0iDawkqYy1u5MBZsCfGN4H0AhlvM
nza5wfjLmZybNIRv+dzHgDdM+DlBE/vDkax4jeJjEmgk0fnTJvfdcgvNjVLPuvUu
NmET2XE6snipIx1cF/s2LUumpO+zYGy57W6PeX/6WUxLrRHqi4cC2mZlHyRHdsr9
mQIPR6u7KfaLz8bio1VFwTd9lmCKoL794o5zzX9NmYe/kveteiA4VTtLrTfSVQ7Q
s+lwSliS0AjicOaG3Bh3RvnxgMZbDU1wwBGYQC7h1gpO7YuhBDRHZSIweR9JVdcm
cxxadZo48zM1lRn8kpHvwv1jIS+LMTl5z0KgifdN1LYh5ROShehxJm6QKFc0+sFe
OkpupqEp+V4vurMVRrdkXQ+y/XOjN2BbMtM61CvqlB4O7TcdK4Fcmm6cy+NARWwY
NL0J6S+Fk0gwms9t+jA+ZIREKsfjvl+Rtrtk1aLQb6XA/6vAVgZz2vmrJK8MQFNr
ENXNVcq7avGj/q1AF8bA
=m0uc
-----END PGP SIGNATURE-----

--4dbYIUm7Fhfg+fSv--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019