Changes between Version 3 and Version 4 of Ticket #40, comment 96


Ignore:
Timestamp:
May 9, 2017, 2:58:57 PM (8 years ago)
Author:
erdmann

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #40, comment 96

    v3 v4  
    22
    331) the doc for "DosQueryPathInfo" says that each GEA2 element must be DWORD aligned.I don't know if that is really true. I don't think so.[[BR]]
    4 2) the GEA2List is TIGHTLY PACKED. That means you cannot allocate a separate buffer for the list and the GEA2. Likewise the GEA2LIST structure does not give you room for a complete GEA2 structure. That's because the EA Name has to DIRECTLY follow the GEA2 structure and it is of variable length:
     42) the FEA2List and GEA2List are TIGHTLY PACKED. That means you cannot allocate a separate buffer for the list and the FEA2 / GEA2. Likewise the FEA2LIST / GEA2LIST structure does not give you room for a complete FEA2/GEA2 structure. That's because the EA Name has to DIRECTLY follow the FEA2/GEA2 structure and it is of variable length, FEA2, the value of the EA follows the EA Name:
    55
    66
    77{{{
    88char gea2list[512];
     9char fea2list[4096];
    910
    1011eaop2.fpGEA2List = (PGEA2LIST)gea2list;
     12eaop2.fpFEA2List = (PFEA2LIST)fea2list;
     13
    1114strcpy(eaop2.fpGEA2List->list[0].szName,".SUBJECT");
    1215eaop2.fpGEA2List->list[0].cbName = strlen(".SUBJECT");
    13 eaop2.fpGEA2List->cbList = sizeof(GEA2) + eaop2.fpGEA2List->list[0].cbName;
    14 // but your computation of cbList would be ok
    15 // I think your assumption that it is the max buffer size is ok
     16eaop2.fpGEA2List->cbList = sizeof (eaop2.fpGEA2List->cbList) + sizeof(GEA2) + eaop2.fpGEA2List->list[0].cbName;
    1617
    1718// you can go from one GEA2 to the next: