File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -1207,7 +1207,7 @@ static int qat_engine_finish(ENGINE *e)
12071207 }
12081208
12091209 if (0 == enable_external_polling && !qat_is_event_driven ()) {
1210- if ((pthread_t * ) icp_polling_threads [i ] != 0 ) {
1210+ if ((pthread_t * ) icp_polling_threads [i ] != NULL ) {
12111211 pthread_join (icp_polling_threads [i ], NULL );
12121212 }
12131213 }
@@ -1217,7 +1217,7 @@ static int qat_engine_finish(ENGINE *e)
12171217 }
12181218
12191219 if (0 == enable_external_polling && qat_is_event_driven ()) {
1220- if ((pthread_t * ) icp_polling_threads [0 ] != 0 ) {
1220+ if ((pthread_t * ) icp_polling_threads [0 ] != NULL ) {
12211221 pthread_join (icp_polling_threads [0 ], NULL );
12221222 }
12231223 }
Original file line number Diff line number Diff line change @@ -327,12 +327,13 @@ static unsigned long pkt_threshold_table_hash(const PKT_THRESHOLD * a)
327327LHASH_OF (PKT_THRESHOLD ) * qat_create_pkt_threshold_table (void )
328328{
329329 int i ;
330+ int tbl_size = (sizeof (qat_pkt_threshold_table ) / sizeof (qat_pkt_threshold_table [0 ]));
330331 LHASH_OF (PKT_THRESHOLD ) * ret = NULL ;
331332 ret = lh_PKT_THRESHOLD_new (pkt_threshold_table_hash ,pkt_threshold_table_cmp );
332333 if (ret == NULL ) {
333334 return ret ;
334335 }
335- for (i = 0 ; i < sizeof ( qat_pkt_threshold_table ); i ++ ) {
336+ for (i = 0 ; i < tbl_size ; i ++ ) {
336337 lh_PKT_THRESHOLD_insert (ret ,& qat_pkt_threshold_table [i ]);
337338 }
338339 return ret ;
You can’t perform that action at this time.
0 commit comments