Changeset e9fe6ac


Ignore:
Timestamp:
01/16/19 11:47:26 (23 months ago)
Author:
Shane Alcock <salcock@…>
Branches:
develop
Children:
ab3ddbe
Parents:
bab946c
Message:

Use a #defined constant for SLL header size

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/format_linux_int.c

    rfce4572 re9fe6ac  
    5353#include "format_linux_common.h"
    5454
     55#define SLL_HEADER_LENGTH 6
    5556
    5657#ifdef HAVE_NETPACKET_PACKET_H
     
    368369        hdr.sll_hatype = 0;
    369370        hdr.sll_pkttype = 0;
    370         hdr.sll_halen = htons(6); /* FIXME */
    371         memcpy(hdr.sll_addr,packet->payload,(size_t)ntohs(hdr.sll_halen));
     371        hdr.sll_halen = htons(SLL_HEADER_LENGTH); /* FIXME */
     372        memcpy(hdr.sll_addr,packet->payload,(size_t)SLL_HEADER_LENGTH);
    372373
    373374        /* This is pretty easy, just send the payload using sendto() (after
Note: See TracChangeset for help on using the changeset viewer.