From bd5d079c02bf22ad1ddfe355ab2bb9a43bfc830f Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Wed, 21 Nov 2018 12:35:43 -0600 Subject: [PATCH] arch/mips/src/pic32m[x|z]/pic32m[x|z]-ethernet.c: Fix a comparison in a debug assertion. Should be <= vs <. Noted by Anonymous in Bitbucket Isue 134. --- arch/mips/src/pic32mx/pic32mx-ethernet.c | 2 +- arch/mips/src/pic32mz/pic32mz-ethernet.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/mips/src/pic32mx/pic32mx-ethernet.c b/arch/mips/src/pic32mx/pic32mx-ethernet.c index e81dbdabe00..693848f6696 100644 --- a/arch/mips/src/pic32mx/pic32mx-ethernet.c +++ b/arch/mips/src/pic32mx/pic32mx-ethernet.c @@ -1021,7 +1021,7 @@ static int pic32mx_transmit(struct pic32mx_driver_s *priv) */ DEBUGASSERT(priv->pd_dev.d_buf != NULL && - priv->pd_dev.d_len < CONFIG_NET_ETH_PKTSIZE); + priv->pd_dev.d_len <= CONFIG_NET_ETH_PKTSIZE); /* Increment statistics and dump the packet (if so configured) */ diff --git a/arch/mips/src/pic32mz/pic32mz-ethernet.c b/arch/mips/src/pic32mz/pic32mz-ethernet.c index 76f06a90e3d..2445de249ba 100644 --- a/arch/mips/src/pic32mz/pic32mz-ethernet.c +++ b/arch/mips/src/pic32mz/pic32mz-ethernet.c @@ -1048,7 +1048,7 @@ static int pic32mz_transmit(struct pic32mz_driver_s *priv) */ DEBUGASSERT(priv->pd_dev.d_buf != NULL && - priv->pd_dev.d_len < CONFIG_NET_ETH_PKTSIZE); + priv->pd_dev.d_len <= CONFIG_NET_ETH_PKTSIZE); /* Increment statistics and dump the packet (if so configured) */