Changeset e846bec in mainline for uspace/lib/pcap


Ignore:
Timestamp:
2024-03-10T10:46:00Z (2 years ago)
Author:
Nataliia Korop <n.corop08@…>
Children:
e4cc266
Parents:
325ea9c (diff), 6eab537d (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'topic/packet-capture' into topic/packet-capture-list

Location:
uspace/lib/pcap
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/pcap/include/pcap.h

    r325ea9c re846bec  
    6464        uint32_t snaplen;
    6565        uint32_t additional; /** The LinkType and additional information field is in the form */
    66 } __attribute__((packed, aligned(4))) pcap_file_header_t;
     66} pcap_file_header_t;
    6767
    6868typedef struct pcap_packet_header {
  • uspace/lib/pcap/src/pcap.c

    r325ea9c re846bec  
    3535 * @brief Headers and functions for .pcap file and packets to be dumped
    3636 */
    37 
    38 #define LOGGER(msg, ...) \
    39      fprintf(stderr, \
    40          "[PCAP %s:%d]: " msg "\n", \
    41          __FILE__, __LINE__, \
    42          ##__VA_ARGS__\
    43      )
    4437
    4538#include "pcap.h"
     
    108101        if (writer->data == NULL) {
    109102                rc = EINVAL;
    110                 LOGGER("Failed to create %s: %s.", filename, str_error(rc));
    111103                return rc;
    112104        }
  • uspace/lib/pcap/src/pcap_iface.c

    r325ea9c re846bec  
    8282}
    8383
    84 void pcap_close_file()
     84void pcap_close_file(void)
    8585{
    8686        pcap_writer.ops->close(&pcap_writer);
Note: See TracChangeset for help on using the changeset viewer.