Skip to content

Feature request: Function to get pcapng file size #41

@cmcqueen

Description

@cmcqueen

While logging output live to a pcapng file, I'm interested to implement a log limit based on the output file size. So I would like to be able to call a light_io.h function to get the file size. Eg maybe light_io_get_size() or light_io_tell().

struct light_file_t could have a fn_tell function pointer added to it.

In the case of light_io_file.c, it could be implemented with return ftell(file).

I'm not sure what would be a good implementation for light_io_zlib.c etc.

Note, I see there is a light_file_seek() which is not used in fd->fn_seek.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions