The purpose of this patch is to make the code more readable and
fix a static analyzer warning.
Signed-off-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
Acked-by: Sairam Venugopal <vsairam@vmware.com>
Signed-off-by: Gurucharan Shetty <guru@ovn.org>
/* L2 header */
ethHdr = (EthHdr *)bufferStart;
- ASSERT(((PCHAR)&fwdInfo->dstMacAddr + sizeof fwdInfo->dstMacAddr) ==
- (PCHAR)&fwdInfo->srcMacAddr);
NdisMoveMemory(ethHdr->Destination, fwdInfo->dstMacAddr,
- sizeof ethHdr->Destination + sizeof ethHdr->Source);
+ sizeof ethHdr->Destination);
+ NdisMoveMemory(ethHdr->Source, fwdInfo->srcMacAddr,
+ sizeof ethHdr->Source);
ethHdr->Type = htons(ETH_TYPE_IPV4);
#if DBG
counterHeadRoom -= sizeof *ethHdr;