Define LWIP_CHKSUM_COPY_ALGORITHM when port provides LWIP_CHKSUM_COPY macro

When the port has LWIP_CHECKSUM_ON_COPY enabled and provides
a definition of LWIP_CHKSUM_COPY, the existing logic left
LWIP_CHKSUM_COPY_ALGORITHM undefined

In this case we want it to be defined to 0 since none of the copy
checksum algorithms provided are being used

This commit also introduces indentation matching LWIP_CHKSUM to
improve the readability of the code
This commit is contained in:
Joel Cunningham 2016-01-20 11:34:25 -06:00
parent 0a67c06b51
commit 96373f6959

View File

@ -61,6 +61,8 @@
# ifndef LWIP_CHKSUM_COPY_ALGORITHM
# define LWIP_CHKSUM_COPY_ALGORITHM 1
# endif /* LWIP_CHKSUM_COPY_ALGORITHM */
# else /* LWIP_CHKSUM_COPY */
# define LWIP_CHKSUM_COPY_ALGORITHM 0
# endif /* LWIP_CHKSUM_COPY */
#else /* LWIP_CHECKSUM_ON_COPY */
# define LWIP_CHKSUM_COPY_ALGORITHM 0