@@ -917,7 +917,7 @@ int wc_HpkeInitSealContext(Hpke* hpke, HpkeBaseContext* context,
917917 void * ephemeralKey , void * receiverKey , byte * info , word32 infoSz )
918918{
919919 if (hpke == NULL || context == NULL || ephemeralKey == NULL ||
920- receiverKey == NULL || (info == NULL && infoSz > 0 )) {
920+ receiverKey == NULL || (info == NULL && infoSz != 0 )) {
921921 return BAD_FUNC_ARG ;
922922 }
923923
@@ -935,7 +935,7 @@ int wc_HpkeContextSealBase(Hpke* hpke, HpkeBaseContext* context,
935935 int ret ;
936936 byte nonce [HPKE_Nn_MAX ];
937937 WC_DECLARE_VAR (aes , Aes , 1 , 0 );
938- if (hpke == NULL || context == NULL || (aad == NULL && aadSz > 0 ) ||
938+ if (hpke == NULL || context == NULL || (aad == NULL && aadSz != 0 ) ||
939939 plaintext == NULL || out == NULL ) {
940940 return BAD_FUNC_ARG ;
941941 }
@@ -1160,7 +1160,7 @@ int wc_HpkeInitOpenContext(Hpke* hpke, HpkeBaseContext* context,
11601160 word32 infoSz )
11611161{
11621162 if (hpke == NULL || context == NULL || receiverKey == NULL || pubKey == NULL
1163- || (info == NULL && infoSz > 0 )) {
1163+ || (info == NULL && infoSz != 0 )) {
11641164 return BAD_FUNC_ARG ;
11651165 }
11661166
@@ -1175,7 +1175,7 @@ int wc_HpkeContextOpenBase(Hpke* hpke, HpkeBaseContext* context, byte* aad,
11751175 int ret ;
11761176 byte nonce [HPKE_Nn_MAX ];
11771177 WC_DECLARE_VAR (aes , Aes , 1 , 0 );
1178- if (hpke == NULL || context == NULL || (aad == NULL && aadSz > 0 ) ||
1178+ if (hpke == NULL || context == NULL || (aad == NULL && aadSz != 0 ) ||
11791179 ciphertext == NULL || out == NULL ) {
11801180 return BAD_FUNC_ARG ;
11811181 }
0 commit comments