Skip to content

Commit

Permalink
[pua] force pres_id a unsigned_int during calculation
Browse files Browse the repository at this point in the history
To avoid any issues due to "singed" overflowing

(cherry picked from commit ac99224)
  • Loading branch information
bogdan-iancu committed Jan 31, 2023
1 parent 50e7f58 commit 2095069
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/pua/hash.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
#define MAX_FORWARD 70

#define PRES_HASH_ID(presentity) \
(HASH_SIZE*(long)presentity->local_index + presentity->hash_index)
(unsigned long)(HASH_SIZE*(unsigned long)presentity->local_index + presentity->hash_index)

typedef struct publ
{
Expand Down

0 comments on commit 2095069

Please sign in to comment.