From: Victor Julien Date: Mon, 13 Jan 2025 19:46:58 +0000 (+0100) Subject: app-layer: constify AppLayerGetProtoByName X-Git-Tag: suricata-8.0.0-beta1~283 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f5e4c52f44678755f18df0d27c9a871d1100b5f0;p=thirdparty%2Fsuricata.git app-layer: constify AppLayerGetProtoByName --- diff --git a/src/app-layer.c b/src/app-layer.c index 448cdc1066..e653348730 100644 --- a/src/app-layer.c +++ b/src/app-layer.c @@ -998,7 +998,7 @@ int AppLayerHandleUdp(ThreadVars *tv, AppLayerThreadCtx *tctx, Packet *p, Flow * /***** Utility *****/ -AppProto AppLayerGetProtoByName(char *alproto_name) +AppProto AppLayerGetProtoByName(const char *alproto_name) { SCEnter(); AppProto r = AppLayerProtoDetectGetProtoByName(alproto_name); diff --git a/src/app-layer.h b/src/app-layer.h index 1dea87ee34..a80c8cef17 100644 --- a/src/app-layer.h +++ b/src/app-layer.h @@ -63,7 +63,7 @@ int AppLayerHandleUdp(ThreadVars *tv, AppLayerThreadCtx *app_tctx, * * \param The internal protocol id. */ -AppProto AppLayerGetProtoByName(char *alproto_name); +AppProto AppLayerGetProtoByName(const char *alproto_name); /** * \brief Given the internal protocol id, returns a string representation