detect: use bool for uint16_t used as bool

pull/6680/head
Victor Julien 3 years ago
parent 6d7c1519ed
commit bb3d49d5bf

@ -1408,7 +1408,7 @@ static void DetectRunTx(ThreadVars *tv,
RulesDumpTxMatchArray(det_ctx, scratch->sgh, p, tx.tx_id, array_idx, x);
#endif
det_ctx->tx_id = tx.tx_id;
det_ctx->tx_id_set = 1;
det_ctx->tx_id_set = true;
det_ctx->p = p;
/* run rules: inspect the match candidates */
@ -1476,7 +1476,7 @@ static void DetectRunTx(ThreadVars *tv,
}
det_ctx->tx_id = 0;
det_ctx->tx_id_set = 0;
det_ctx->tx_id_set = false;
det_ctx->p = NULL;
/* see if we have any updated state to store in the tx */

@ -1066,8 +1066,8 @@ typedef struct DetectEngineThreadCtx_ {
uint16_t discontinue_matching;
uint16_t flags;
/* bool: if tx_id is set, this is 1, otherwise 0 */
uint16_t tx_id_set;
/* true if tx_id is set */
bool tx_id_set;
/** ID of the transaction currently being inspected. */
uint64_t tx_id;
Packet *p;

Loading…
Cancel
Save