Skip to content

Commit

Permalink
Compilation fix on RH7
Browse files Browse the repository at this point in the history
  • Loading branch information
lucaderi committed Apr 24, 2023
1 parent d3e67fa commit c4ba981
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/lib/protocols/hots.c
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ static void ndpi_hots_add_connection(struct ndpi_detection_module_struct *ndpi_s
void ndpi_search_hots(struct ndpi_detection_module_struct *ndpi_struct, struct ndpi_flow_struct *flow)
{
struct ndpi_packet_struct *packet = &ndpi_struct->packet;
int i, ports[4] = {1119, 1120, 3724, 6113};

NDPI_LOG_DBG(ndpi_struct, "search Heroes of the Storm\n");

int ports[4] = {1119, 1120, 3724, 6113};
for (int i = 0; i < 4; i++) {
for (i = 0; i < 4; i++) {
if (packet->udp->dest == ntohs(ports[i]) || packet->udp->source == ntohs(ports[i])) {
if (packet->payload_packet_len >= 20 && packet->payload_packet_len <= 122) {
if (packet->payload[14] == 0x40 && packet->payload[15] == 0x00) {
Expand Down Expand Up @@ -72,4 +72,4 @@ void init_hots_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
SAVE_DETECTION_BITMASK_AS_UNKNOWN,
ADD_TO_DETECTION_BITMASK);
*id += 1;
}
}

0 comments on commit c4ba981

Please sign in to comment.