Cygwin: drop CYGWIN_SOCKET_UUID, define CYGWIN_SOCKET_GUID as GUID pointer
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
parent
d87ef0dac9
commit
1949db7829
|
@ -34,6 +34,14 @@ static int __unused
|
|||
get_inet_addr_unix (const struct sockaddr *in, int inlen,
|
||||
struct sockaddr_storage *out, int *outlen,
|
||||
int *type = NULL)
|
||||
GUID __cygwin_socket_guid = {
|
||||
.Data1 = 0xefc1714d,
|
||||
.Data2 = 0x7b19,
|
||||
.Data3 = 0x4407,
|
||||
.Data4 = { 0xba, 0xb3, 0xc5, 0xb1, 0xf9, 0x2c, 0xb8, 0x8c }
|
||||
};
|
||||
|
||||
HANDLE
|
||||
{
|
||||
/* Check for abstract socket. */
|
||||
if (inlen >= (int) sizeof (in->sa_family) + 7
|
||||
|
|
|
@ -10,9 +10,10 @@
|
|||
|
||||
#include <w32api/ntstatus.h>
|
||||
|
||||
/* Special values for Cygwin AF_UNIX socket reparse points. */
|
||||
/* Values for Cygwin AF_UNIX socket reparse points. */
|
||||
#define IO_REPARSE_TAG_CYGUNIX (0x00006375)
|
||||
#define CYGWIN_SOCKET_UUID L"efc1714d-7b19-4407-bab3-c5b1f92cb88c"
|
||||
extern GUID __cygwin_socket_guid;
|
||||
#define CYGWIN_SOCKET_GUID (&__cygwin_socket_guid)
|
||||
|
||||
/* custom status code: */
|
||||
#define STATUS_ILLEGAL_DLL_PSEUDO_RELOCATION ((NTSTATUS) 0xe0000269)
|
||||
|
|
|
@ -65,7 +65,6 @@
|
|||
#include "shared_info.h"
|
||||
#include "tls_pbuf.h"
|
||||
#include "environ.h"
|
||||
#include "uuid.h"
|
||||
#undef basename
|
||||
|
||||
suffix_info stat_suffixes[] =
|
||||
|
@ -2356,10 +2355,8 @@ check_reparse_point_target (HANDLE h, bool remote, PREPARSE_DATA_BUFFER rp,
|
|||
else if (rp->ReparseTag == IO_REPARSE_TAG_CYGUNIX)
|
||||
{
|
||||
PREPARSE_GUID_DATA_BUFFER rgp = (PREPARSE_GUID_DATA_BUFFER) rp;
|
||||
UUID uuid;
|
||||
|
||||
uuid_from_string (CYGWIN_SOCKET_UUID, uuid);
|
||||
if (memcmp (&uuid, &rgp->ReparseGuid, sizeof (UUID)) == 0)
|
||||
if (memcmp (CYGWIN_SOCKET_GUID, &rgp->ReparseGuid, sizeof (GUID)) == 0)
|
||||
return PATH_SOCKET | PATH_REP;
|
||||
}
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue