Windows NT 4.0 source code leak
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.

85 lines
2.2 KiB

4 years ago
  1. /********************************************************************/
  2. /** Microsoft LAN Manager **/
  3. /** Copyright(c) Microsoft Corp., 1990-1992 **/
  4. /********************************************************************/
  5. /* :ts=4 */
  6. #ifndef OSCFG_INCLUDED
  7. #define OSCFG_INCLUDED
  8. #define net_short(x) ((((x)&0xff) << 8) | (((x)&0xff00) >> 8))
  9. //#define net_long(x) (((net_short((x)&0xffff)) << 16) | net_short((((x)&0xffff0000L)>>16)))
  10. #define net_long(x) (((((ulong)(x))&0xffL)<<24) | \
  11. ((((ulong)(x))&0xff00L)<<8) | \
  12. ((((ulong)(x))&0xff0000L)>>8) | \
  13. ((((ulong)(x))&0xff000000L)>>24))
  14. #define MIN(a,b) ((a) < (b) ? (a) : (b))
  15. #define MAX(a,b) ((a) > (b) ? (a) : (b))
  16. #ifdef VXD
  17. /////////////////////////////////////////////////////////////////////////////
  18. //
  19. // VXD definitions
  20. //
  21. ////////////////////////////////////////////////////////////////////////////
  22. #include <stddef.h>
  23. #ifndef CHICAGO
  24. #pragma code_seg("_LTEXT", "LCODE")
  25. #pragma data_seg("_LDATA", "LCODE")
  26. //* pragma bodies for bracketing of initialization code.
  27. #define BEGIN_INIT code_seg("_ITEXT", "ICODE")
  28. #define BEGIN_INIT_DATA data_seg("_IDATA", "ICODE")
  29. #define END_INIT code_seg()
  30. #define END_INIT_DATA data_seg()
  31. #else // CHICAGO
  32. #define INNOCUOUS_PRAGMA warning(4:4206) // Source File is empty
  33. #define BEGIN_INIT INNOCUOUS_PRAGMA
  34. #define BEGIN_INIT_DATA INNOCUOUS_PRAGMA
  35. #define END_INIT INNOCUOUS_PRAGMA
  36. #define END_INIT_DATA INNOCUOUS_PRAGMA
  37. #endif // CHICAGO
  38. #else // VXD
  39. #ifdef NT
  40. //////////////////////////////////////////////////////////////////////////////
  41. //
  42. // NT definitions
  43. //
  44. //////////////////////////////////////////////////////////////////////////////
  45. #include <ntos.h>
  46. #include <zwapi.h>
  47. #define BEGIN_INIT
  48. #define END_INIT
  49. #else // NT
  50. /////////////////////////////////////////////////////////////////////////////
  51. //
  52. // Definitions for additional environments go here
  53. //
  54. /////////////////////////////////////////////////////////////////////////////
  55. #error Environment specific definitions missing
  56. #endif // NT
  57. #endif // VXD
  58. #endif // OSCFG_INCLUDED