Function lrs::file::get_attr_buf

Retrieves an attribute of a file.

Syntax

fn get_attr_buf<P, S>(path: P, name: S, buf: &mut [u8]) -> Result<usize, Errno>
    where P: ToCString,
          S: ToCString,

Arguments

NameDescription
path

The path of the file whose attribute we want to retrieve.

name

The name of the attribute to retrieve.

buf

The buffer in which the attribute will be stored.

Return value

The number of bytes stored in the buffer.

Remarks

If the path refers to a symbolic link, the link will be recursively resolved and the attribute of the first non-link target will be retrieved.

If the path is relative, it will be interpreted relative to the current working directory.

See also