Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

117 lines
4.4 KiB

  1. /****************************************************************************/
  2. // wtdint.h
  3. //
  4. // Transport driver - Windows specific internal functions.
  5. //
  6. // Copyright (C) 1997-1999 Microsoft Corporation
  7. /****************************************************************************/
  8. #ifndef _H_WTDINT
  9. #define _H_WTDINT
  10. #ifdef OS_WINCE
  11. typedef unsigned long u_long;
  12. #endif
  13. /****************************************************************************/
  14. /* Define the window class name. */
  15. /****************************************************************************/
  16. #define TD_WNDCLASSNAME _T("TDWindowClass")
  17. /****************************************************************************/
  18. /* Define the async message name. */
  19. /****************************************************************************/
  20. #define TD_WSA_ASYNC (DUC_TD_MESSAGE_BASE + 0)
  21. /****************************************************************************/
  22. /* Define the gethostbyname message name. */
  23. /****************************************************************************/
  24. #define TD_WSA_GETHOSTBYNAME (DUC_TD_MESSAGE_BASE + 1)
  25. #if (defined(OS_WINCE) && (_WIN32_WCE > 300))
  26. /****************************************************************************/
  27. /* Define the message to handle netdown */
  28. /****************************************************************************/
  29. #define TD_WSA_NETDOWN (DUC_TD_MESSAGE_BASE + 2)
  30. #endif
  31. /****************************************************************************/
  32. /* Define the connect time-out timer id. */
  33. /****************************************************************************/
  34. #define TD_TIMERID 100
  35. /****************************************************************************/
  36. /* The value of the connect time-out (in milliseconds). */
  37. /****************************************************************************/
  38. #define TD_CONNECTTIMEOUT 10000
  39. /****************************************************************************/
  40. /* The value of the disconnect time-out (in milliseconds). */
  41. /****************************************************************************/
  42. #define TD_DISCONNECTTIMEOUT 1000
  43. /****************************************************************************/
  44. // WinSock receive and send buffer sizes.
  45. // Receive needs to be tuned to handle general server buffer send.
  46. /****************************************************************************/
  47. #define TD_WSSNDBUFSIZE 4096
  48. #define TD_WSRCVBUFSIZE 8192
  49. #ifdef DC_DEBUG
  50. /****************************************************************************/
  51. /* Throughput timer id and time interval in ms. */
  52. /****************************************************************************/
  53. #define TD_THROUGHPUTTIMERID 101
  54. #define TD_THROUGHPUTINTERVAL 100
  55. #endif /* DC_DEBUG */
  56. /****************************************************************************/
  57. /* FUNCTIONS */
  58. /****************************************************************************/
  59. DCVOID DCINTERNAL TDInit(DCVOID);
  60. DCVOID DCINTERNAL TDTerm(DCVOID);
  61. LRESULT CALLBACK TDWndProc(HWND hWnd,
  62. UINT uMsg,
  63. WPARAM wParam,
  64. LPARAM lParam);
  65. //
  66. // Delegates to appropriate TD instance
  67. //
  68. static LRESULT CALLBACK StaticTDWndProc(HWND hWnd,
  69. UINT uMsg,
  70. WPARAM wParam,
  71. LPARAM lParam);
  72. DCVOID DCINTERNAL TDCreateWindow(DCVOID);
  73. DCVOID DCINTERNAL TDBeginDNSLookup(PDCACHAR ServerAddress);
  74. DCVOID DCINTERNAL TDBeginSktConnect(u_long Address);
  75. DCVOID DCINTERNAL TDSetSockOpt(DCINT level, DCINT optName, DCINT value);
  76. DCVOID DCINTERNAL TDDisconnect(DCVOID);
  77. DCBOOL DCINTERNAL TDSetTimer(DCUINT timeInterval);
  78. DCVOID DCINTERNAL TDKillTimer(DCVOID);
  79. #ifdef OS_WINCE
  80. static DWORD WINAPI TDAddrChangeProc(LPVOID lpParameter);
  81. #endif
  82. DCVOID DCINTERNAL TDBeginSktConnectWithConnectedEndpoint();
  83. #endif /* _H_WTDINT */