' ########################################################################################
' Microsoft Windows
' File: wsvns.inc
' Contents: Interfaces for Windows Parental Controls clients
' Copyright (c) 2011 Jos? Roca
' Portions Copyright (c) Microsoft Corporation.
' All Rights Reserved.
' THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER
' EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
' MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
' ########################################################################################
' * Copyright (C) Microsoft Corporation, 1992-1999.
' *
' * Windows Sockets include file for VINES IP. This file contains all
' * standardized VINES IP information. Include this header file after
' * winsock.h.
' *
' * To open an VINES IP socket, call socket() with an address family of
' * AF_BAN, a socket type of SOCK_DGRAM, SOCK_STREAM, or SOCK_SEQPACKET,
' * and protocol of 0.
#IF NOT %DEF(PBX_WSvns_PBI)
#DEFINE PBX_WSvns_PBI
%EQUATE `WSVNS_INC = 1
'/*
' * Socket address, VINES IP style. Address fields and port field are defined
' * as a sequence of bytes. This is done because they are byte ordered
' * BIG ENDIAN, ala most significant byte first.
' */
' // Size = 16 bytes
TYPE SOCKADDR_VNS BYTE
 sin_family AS WORD ' u_short // = AF_BAN
 net_address(3) AS BYTE ' u_char[4] // network address
 subnet_addr(1) AS BYTE ' u_char[2] // subnet address
 port(1) AS BYTE ' u_char[2] // msb=port[0], lsb=port[1]
 hops AS BYTE ' u_char // # hops for broadcasts
 filler(4) AS BYTE ' u_cahr[5] // filler, zeros
END TYPE
%EQUATE `VNSPROTO_IPC = 1
%EQUATE `VNSPROTO_RELIABLE_IPC = 2
%EQUATE `VNSPROTO_SPP = 3
#ENDIF
