* Sending data required sockaddr_dl addresses without an interface name; it can
now deal with any sockaddr_dl as one would expect. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@39721 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -153,11 +153,11 @@ ethernet_frame_send_data(net_datalink_protocol* protocol, net_buffer* buffer)
|
|||||||
ether_header &header = bufferHeader.Data();
|
ether_header &header = bufferHeader.Data();
|
||||||
|
|
||||||
header.type = htons(source.sdl_e_type);
|
header.type = htons(source.sdl_e_type);
|
||||||
memcpy(header.source, source.sdl_data, ETHER_ADDRESS_LENGTH);
|
memcpy(header.source, LLADDR(&source), ETHER_ADDRESS_LENGTH);
|
||||||
if ((buffer->flags & MSG_BCAST) != 0)
|
if ((buffer->flags & MSG_BCAST) != 0)
|
||||||
memcpy(header.destination, kBroadcastAddress, ETHER_ADDRESS_LENGTH);
|
memcpy(header.destination, kBroadcastAddress, ETHER_ADDRESS_LENGTH);
|
||||||
else
|
else
|
||||||
memcpy(header.destination, destination.sdl_data, ETHER_ADDRESS_LENGTH);
|
memcpy(header.destination, LLADDR(&destination), ETHER_ADDRESS_LENGTH);
|
||||||
|
|
||||||
bufferHeader.Sync();
|
bufferHeader.Sync();
|
||||||
// make sure the framing is already written to the buffer at this point
|
// make sure the framing is already written to the buffer at this point
|
||||||
|
|||||||
Reference in New Issue
Block a user