Exemplo n.º 1
0
        private static IReadOnlyList <MountPoint> ParseMountPoints(SafeStructureInOutBuffer <MOUNTMGR_MOUNT_POINTS> buffer, int length)
        {
            buffer.Initialize((uint)length);
            var result = buffer.Result;

            MOUNTMGR_MOUNT_POINT[] mount_point = new MOUNTMGR_MOUNT_POINT[result.NumberOfMountPoints];
            buffer.Data.ReadArray(0, mount_point, 0, mount_point.Length);

            return(mount_point.Select(m => new MountPoint(buffer, m)).ToList().AsReadOnly());
        }