Home | Info | Community | Development | myReactOS | Contact Us
ReactOS Development > Doxygenqos.c
Go to the documentation of this file.
00001 /* 00002 * COPYRIGHT: See COPYING in the top level directory 00003 * PROJECT: ReactOS WinSock 2 API 00004 * FILE: qos.c 00005 * PURPOSE: QoS Support 00006 * PROGRAMMER: Alex Ionescu (alex@relsoft.net) 00007 */ 00008 00009 /* INCLUDES ******************************************************************/ 00010 #include "ws2_32.h" 00011 00012 //#define NDEBUG 00013 #include <debug.h> 00014 00015 /* DATA **********************************************************************/ 00016 00017 /* FUNCTIONS *****************************************************************/ 00018 00019 /* 00020 * @implemented 00021 */ 00022 BOOL 00023 WSAAPI 00024 WSAGetQOSByName(IN SOCKET s, 00025 IN OUT LPWSABUF lpQOSName, 00026 OUT LPQOS lpQOS) 00027 { 00028 PWSSOCKET Socket; 00029 INT Status; 00030 INT ErrorCode; 00031 DPRINT("WSAGetQOSByName: %lx, %p\n", s, lpQOSName); 00032 00033 /* Check for WSAStartup */ 00034 if ((ErrorCode = WsQuickProlog()) == ERROR_SUCCESS) 00035 { 00036 /* Get the Socket Context */ 00037 if ((Socket = WsSockGetSocket(s))) 00038 { 00039 /* Make the call */ 00040 Status = Socket->Provider->Service.lpWSPGetQOSByName(s, 00041 lpQOSName, 00042 lpQOS, 00043 &ErrorCode); 00044 00045 /* Deference the Socket Context */ 00046 WsSockDereference(Socket); 00047 00048 /* Return Provider Value */ 00049 if (Status == ERROR_SUCCESS) return Status; 00050 00051 /* If everything seemed fine, then the WSP call failed itself */ 00052 if (ErrorCode == NO_ERROR) ErrorCode = WSASYSCALLFAILURE; 00053 } 00054 else 00055 { 00056 /* No Socket Context Found */ 00057 ErrorCode = WSAENOTSOCK; 00058 } 00059 } 00060 00061 /* Return with an Error */ 00062 SetLastError(ErrorCode); 00063 return FALSE; 00064 } Generated on Sat May 26 2012 04:25:40 for ReactOS by
1.7.6.1
|