So remove the runtime check for it.
return false;
}
-/** \brief simpler way to globally test if a alproto is registered
+/** \brief simple way to globally test if a alproto is registered
* and fully enabled in the configuration.
*/
-int AppLayerParserIsTxAware(AppProto alproto)
+int AppLayerParserIsEnabled(AppProto alproto)
{
return (alp_ctx.ctxs[FLOW_PROTO_DEFAULT][alproto]
.StateGetProgressCompletionStatus != NULL);
uint8_t flags, const uint8_t *input, uint32_t input_len);
void AppLayerParserSetEOF(AppLayerParserState *pstate);
bool AppLayerParserHasDecoderEvents(AppLayerParserState *pstate);
-int AppLayerParserIsTxAware(AppProto alproto);
int AppLayerParserProtocolIsTxEventAware(uint8_t ipproto, AppProto alproto);
int AppLayerParserProtocolHasLogger(uint8_t ipproto, AppProto alproto);
LoggerId AppLayerParserProtocolGetLoggerBits(uint8_t ipproto, AppProto alproto);
void AppLayerParserSetStreamDepth(uint8_t ipproto, AppProto alproto, uint32_t stream_depth);
uint32_t AppLayerParserGetStreamDepth(const Flow *f);
void AppLayerParserSetStreamDepthFlag(uint8_t ipproto, AppProto alproto, void *state, uint64_t tx_id, uint8_t flags);
+int AppLayerParserIsEnabled(AppProto alproto);
/***** Cleanup *****/
AppProto alproto, uint32_t dir,
int progress, InspectEngineFuncPtr Callback)
{
- if (AppLayerParserIsTxAware(alproto)) {
+ if (AppLayerParserIsEnabled(alproto)) {
if (!AppLayerParserSupportsTxDetectFlags(alproto)) {
FatalError(SC_ERR_INITIALIZATION,
"Inspect engine registered for app-layer protocol without "
ThreadDeinitFunc ThreadDeinit,
void (*ThreadExitPrintStats)(ThreadVars *, void *))
{
- if (alproto != ALPROTO_UNKNOWN && !(AppLayerParserIsTxAware(alproto))) {
+ if (alproto != ALPROTO_UNKNOWN && !(AppLayerParserIsEnabled(alproto))) {
SCLogNotice("%s logger not enabled: protocol %s is disabled",
name, AppProtoToString(alproto));
return -1;
}
-
OutputTxLogger *op = SCMalloc(sizeof(*op));
if (op == NULL)
return -1;