Lhasa

- Main Page
- Data Structures
- Files

- Data Structures
- Data Fields

Data Fields
_LHAFileHeader Struct Reference

Structure containing a decoded LZH file header. More...

## Data Fields
char * | path
| Stored path, with Unix-style ('/') path separators.
char * | filename
| File name.
char * | symlink_target
| Target for symbolic link.
char | compress_method [6]
| Compression method.
size_t | compressed_length
| Length of the compressed data.
size_t | length
| Length of the uncompressed data.
uint8_t | header_level
| LZH header format used to store this header.
uint8_t | os_type
| OS type indicator, identifying the OS on which the archive was created.
uint16_t | crc
| 16-bit CRC of the compressed data.
unsigned int | timestamp
| Unix timestamp of the modification time of the file.
uint8_t * | raw_data
| Pointer to a buffer containing the raw header data.
size_t | raw_data_len
| Length of the raw header data.
unsigned int | extra_flags
| Flags bitfield identifying extra data decoded from extended headers.
unsigned int | unix_perms
| Unix permissions, set if LHA_FILE_UNIX_PERMS is set.
unsigned int | unix_uid
| Unix user ID, set if LHA_FILE_UNIX_UID_GID is set.
unsigned int | unix_gid
| Unix group ID, set if LHA_FILE_UNIX_UID_GID is set.
unsigned int | os9_perms
| OS-9 permissions, set if LHA_FILE_OS9_PERMS is set.
char * | unix_username
| Unix username.
char * | unix_group
| Unix group name.
uint16_t | common_crc
| 16-bit CRC of header contents.
uint64_t | win_creation_time
| Windows FILETIME file creation time, set if LHA_FILE_WINDOWS_TIMESTAMPS is set.
uint64_t | win_modification_time
| Windows FILETIME file modification time, set if LHA_FILE_WINDOWS_TIMESTAMPS is set.
uint64_t | win_access_time
| Windows FILETIME file access time, set if LHA_FILE_WINDOWS_TIMESTAMPS is set.

## Detailed Description

Structure containing a decoded LZH file header.

A file header precedes the compressed data of each file stored within an LZH archive. It contains the name of the file, and various additional metadata, some of which is optional, and can depend on the header format, the tool used to create the archive, and the operating system on which it was created.

## Field Documentation

uint16_t _LHAFileHeader::common_crc

16-bit CRC of header contents.

char _LHAFileHeader::compress_method[6]

Compression method.

If the header represents a directory or a symbolic link, the compression method is equal to LHA_COMPRESS_TYPE_DIR.

size_t _LHAFileHeader::compressed_length

Length of the compressed data.

uint16_t _LHAFileHeader::crc

16-bit CRC of the compressed data.

char* _LHAFileHeader::filename

File name.

This is never NULL, except if this is a directory (LHA_COMPRESS_TYPE_DIR), where it is always NULL.

uint8_t _LHAFileHeader::header_level

LZH header format used to store this header.

size_t _LHAFileHeader::length

Length of the uncompressed data.

unsigned int _LHAFileHeader::os9_perms

OS-9 permissions, set if LHA_FILE_OS9_PERMS is set.

char* _LHAFileHeader::path

Stored path, with Unix-style ('/') path separators.

This may be NULL, although if this is a directory (LHA_COMPRESS_TYPE_DIR), it is never NULL.

uint8_t* _LHAFileHeader::raw_data

Pointer to a buffer containing the raw header data.

size_t _LHAFileHeader::raw_data_len

Length of the raw header data.

char* _LHAFileHeader::symlink_target

Target for symbolic link.

This is NULL unless this header represents a symbolic link (LHA_COMPRESS_TYPE_DIR).

unsigned int _LHAFileHeader::timestamp

Unix timestamp of the modification time of the file.

unsigned int _LHAFileHeader::unix_gid

Unix group ID, set if LHA_FILE_UNIX_UID_GID is set.

char* _LHAFileHeader::unix_group

Unix group name.

unsigned int _LHAFileHeader::unix_perms

Unix permissions, set if LHA_FILE_UNIX_PERMS is set.

unsigned int _LHAFileHeader::unix_uid

Unix user ID, set if LHA_FILE_UNIX_UID_GID is set.

char* _LHAFileHeader::unix_username

Unix username.

The documentation for this struct was generated from the following file:

- lha_file_header.h