Skip to content

Use const for some IPv6 structs used as fn args#2969

Merged
IvanNardi merged 1 commit into
ntop:devfrom
utoni:fix/ip6-const-structs
Sep 17, 2025
Merged

Use const for some IPv6 structs used as fn args#2969
IvanNardi merged 1 commit into
ntop:devfrom
utoni:fix/ip6-const-structs

Conversation

@utoni

@utoni utoni commented Sep 17, 2025

Copy link
Copy Markdown
Collaborator

That'll fix warning i.e.:

/home/toni/git/nDPId/nDPId.c: In function ‘ndpi_process_packet’:
/home/toni/git/nDPId/nDPId.c:4443:39: warning: passing argument 2 of ‘ndpi_flowv6_flow_hash’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
 4443 |                                       &ip6->ip6_src,
      |                                       ^~~~~~~~~~~~~

Please sign (check) the below before submitting the Pull Request:

That'll fix warning i.e.:

```
/home/toni/git/nDPId/nDPId.c: In function ‘ndpi_process_packet’:
/home/toni/git/nDPId/nDPId.c:4443:39: warning: passing argument 2 of ‘ndpi_flowv6_flow_hash’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
 4443 |                                       &ip6->ip6_src,
      |                                       ^~~~~~~~~~~~~
```

Signed-off-by: Toni Uhlig <matzeton@googlemail.com>
@sonarqubecloud

Copy link
Copy Markdown

@IvanNardi IvanNardi left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@IvanNardi IvanNardi merged commit 560a4e4 into ntop:dev Sep 17, 2025
31 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants