]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
Rename function pointer var to use the FuncPtr typing convention. Resupply "dns"...
authorAnoop Saldanha <anoopsaldanha@gmail.com>
Sat, 31 Aug 2013 02:36:26 +0000 (08:06 +0530)
committerAnoop Saldanha <anoopsaldanha@gmail.com>
Sun, 29 Sep 2013 17:43:10 +0000 (23:13 +0530)
src/app-layer-detect-proto.c
src/app-layer-parser.c
src/app-layer-parser.h
src/app-layer-protos.c

index 073d598043332349f8610e09c1daa113fb7807ff..76263961ccf363551a6cfac34a80f62a25869254 100644 (file)
@@ -576,8 +576,8 @@ uint16_t AppLayerDetectGetProto(AlpProtoDetectCtx *ctx,
         uint16_t pm_matches = AppLayerDetectGetProtoPMParser(ctx, tctx, f, buf, buflen, flags, ipproto, pm_results);
         uint8_t dir = (flags & STREAM_TOSERVER) ? 0 : 1;
         for (uint16_t i = 0; i < pm_matches; i++) {
-            if (al_proto_table[pm_results[i]].pp_alproto_map[dir] != NULL) {
-                if (pm_results[i] != al_proto_table[pm_results[i]].pp_alproto_map[dir](buf, buflen, NULL)) {
+            if (al_proto_table[pm_results[i]].PPAlprotoMap[dir] != NULL) {
+                if (pm_results[i] != al_proto_table[pm_results[i]].PPAlprotoMap[dir](buf, buflen, NULL)) {
                     /* \todo set event - Needs some deliberation */
                     continue;
                 }
index b4f5e7d5014878a8628019514b2aff1325e4730c..9b86782a7a5c6e446d0d93304f17f4905430545d 100644 (file)
@@ -2280,7 +2280,7 @@ void AppLayerMapProbingParserAgainstAlproto(uint16_t al_proto,
                                             uint8_t flags,
                                             ProbingParserFPtr ProbingParser)
 {
-    al_proto_table[al_proto].pp_alproto_map[(flags & STREAM_TOSERVER) ? 0 : 1] = ProbingParser;
+    al_proto_table[al_proto].PPAlprotoMap[(flags & STREAM_TOSERVER) ? 0 : 1] = ProbingParser;
 
     return;
 }
index 07c42d90973bdb22d48200ae0ee698f3aca0927e..d7e7b5ab31e440b4ce9d4aa82192971ab4728849 100644 (file)
@@ -72,7 +72,7 @@ typedef struct AppLayerProto_ {
     int (*StateGetEventInfo)(const char *event_name,
                              int *event_id, AppLayerEventType *event_type);
 
-    ProbingParserFPtr pp_alproto_map[2];
+    ProbingParserFPtr PPAlprotoMap[2];
     /* The current values taken are STREAM_TOSERVER, STREAM_TOCLIENT */
     uint8_t flags;
 
index 37e3b3499956b540b135296cd8996a30bce1082d..1bfe8c43ce96d09694d431fbc3396044692009ed 100644 (file)
@@ -83,6 +83,8 @@ const char *TmModuleAlprotoToString(enum AppProto proto)
             proto_name = "dnsudp";
             break;
         case ALPROTO_DNS:
+            proto_name = "dns";
+            break;
         case ALPROTO_FAILED:
         case ALPROTO_TEST:
         case ALPROTO_MAX: