Source code of Windows XP (NT5)
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.

100 lines
2.4 KiB

  1. #pragma pack(1)
  2. /*
  3. * Structure and equates of PIF files
  4. */
  5. #define PIFEDITMAXPIF 1024 /* maximum PIF file size we support */
  6. #define PIFEDITMAXPIFL 1024L
  7. #define PIFNAMESIZE 30
  8. #define PIFSTARTLOCSIZE 63
  9. #define PIFDEFPATHSIZE 64
  10. #define PIFPARAMSSIZE 64
  11. #define PIFSHPROGSIZE 64
  12. #define PIFSHDATASIZE 64
  13. #define PIFEXTSIGSIZE 16
  14. #define PIFSIZE 367 /* two bytes less, this is used for checksum */
  15. typedef struct {
  16. char extsig[PIFEXTSIGSIZE];
  17. unsigned short extnxthdrfloff;
  18. unsigned short extfileoffset;
  19. unsigned short extsizebytes;
  20. } PIFEXTHEADER;
  21. #define LASTHEADERPTR 0xFFFF
  22. #define STDHDRSIG "MICROSOFT PIFEX"
  23. #define W386HDRSIG "WINDOWS 386 3.0"
  24. #define W286HDRSIG30 "WINDOWS 286 3.0"
  25. #define WNTHDRSIG31 "WINDOWS NT 3.1"
  26. typedef struct {
  27. char unknown;
  28. char id;
  29. char name[PIFNAMESIZE];
  30. short maxmem;
  31. short minmem;
  32. char startfile[PIFSTARTLOCSIZE];
  33. char MSflags;
  34. char reserved;
  35. char defpath[PIFDEFPATHSIZE];
  36. char params[PIFPARAMSSIZE];
  37. char screen;
  38. char cPages;
  39. unsigned char lowVector;
  40. unsigned char highVector;
  41. char rows;
  42. char cols;
  43. char rowoff;
  44. char coloff;
  45. unsigned short sysmem;
  46. char shprog[PIFSHPROGSIZE];
  47. char shdata[PIFSHDATASIZE];
  48. unsigned char behavior;
  49. unsigned char sysflags;
  50. PIFEXTHEADER stdpifext;
  51. } PIFNEWSTRUCT;
  52. typedef struct {
  53. short maxmem;
  54. short minmem;
  55. unsigned short PfFPriority;
  56. unsigned short PfBPriority;
  57. short PfMaxEMMK;
  58. unsigned short PfMinEMMK;
  59. short PfMaxXmsK;
  60. unsigned short PfMinXmsK;
  61. unsigned long PfW386Flags;
  62. unsigned long PfW386Flags2;
  63. unsigned short PfHotKeyScan;
  64. unsigned short PfHotKeyShVal;
  65. unsigned short PfHotKeyShMsk;
  66. unsigned char PfHotKeyVal;
  67. unsigned char PfHotKeyPad[9];
  68. char params[PIFPARAMSSIZE];
  69. } PIF386EXT;
  70. /* Windows NT extension format */
  71. typedef struct
  72. {
  73. DWORD dwWNTFlags;
  74. DWORD dwRes1;
  75. DWORD dwRes2;
  76. char achConfigFile[PIFDEFPATHSIZE];
  77. char achAutoexecFile[PIFDEFPATHSIZE];
  78. } PIFWNTEXT;
  79. // equates for dwWNTFlags
  80. #define NTPIF_SUBSYSMASK 0x0000000F // sub system type mask
  81. #define SUBSYS_DEFAULT 0
  82. #define SUBSYS_DOS 1
  83. #define SUBSYS_WOW 2
  84. #define SUBSYS_OS2 3
  85. #define PIFWNTEXTSIZE sizeof(PIFWNTEXT)
  86. #pragma pack()