Bill Fischofer(Bill-Fischofer-Linaro) replied on github web page:

test/validation/api/crypto/odp_crypto_test_inp.c
line 6
@@ -201,6 +201,9 @@ static int alg_packet_op(odp_packet_t pkt,
                return rc;
        }
 
+       if (!result.ok)
+               CU_ASSERT(odp_packet_has_error(pkt));
+


Comment:
`CU_ASSERT(result.ok || odp_packet_has_error(pkt));` is simpler.

> Bill Fischofer(Bill-Fischofer-Linaro) wrote:
> `CU_ASSERT()` needs to be enclosed in braces when used in an `if/else` 
> statement. However a simpler test is just:
> ```
> CU_ASSERT(result.ok != odp_packet_has_error(pkt));
> ```


https://github.com/Linaro/odp/pull/294#discussion_r150419652
updated_at 2017-11-12 19:10:34

Reply via email to