Mail Archives: cygwin/2015/10/23/05:20:34
--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 -