Skip to content

Commit

Permalink
common.h: fix BPF_LICENSE() macro
Browse files Browse the repository at this point in the history
Fix incorrect definition of the BPF_LICENSE() MACRO utility.
  • Loading branch information
msune committed Aug 25, 2024
1 parent b9bf590 commit 2d04746
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,8 @@ static __always_inline __be16 csum_fold(__s64 csum)
}

#ifndef BPF_LICENSE
#define BPF_LICENSE(NAME) char _license[] SEC( NAME ) = NAME
#define BPF_LICENSE(NAME) \
char ____license[] __attribute__((section("license"), used)) = NAME
#endif

//XXX: to be removed by dynamic config
Expand Down

0 comments on commit 2d04746

Please sign in to comment.