Example #1
0
 public static void WriteList(byte[] buffer, int offset, List <FileFullEAEntry> list)
 {
     for (int index = 0; index < list.Count; index++)
     {
         FileFullEAEntry entry = list[index];
         entry.WriteBytes(buffer, offset);
         int entryLength = entry.Length;
         offset += entryLength;
         if (index < list.Count - 1)
         {
             // When multiple FILE_FULL_EA_INFORMATION data elements are present in the buffer, each MUST be aligned on a 4-byte boundary
             int padding = (4 - (entryLength % 4)) % 4;
             offset += padding;
         }
     }
 }