Message ID | DM4PR14MB4880E9DA5E6C6A287EB85E77A8A62@DM4PR14MB4880.namprd14.prod.outlook.com (mailing list archive) |
---|---|
State | Accepted, archived |
Headers | show |
Series | main: remove static from const strlen src/p2putil.c: In function 'p2p_get_random_string': src/p2putil.c:2641:37: error: initializer element is not constant 2641 | static const int set_size = strlen(CHARSET); | ^~~~~~ | expand |
diff --git a/src/p2putil.c b/src/p2putil.c index d1f114d0..ef0f988c 100644 --- a/src/p2putil.c +++ b/src/p2putil.c @@ -2638,7 +2638,7 @@ void p2p_get_random_string(char *buf, size_t len) { #define CHARSET "ABCDEFGHIJKLMNOPQRSTUVWXYZ" "abcdefghijklmnopqrstuvwxyz" \ "0123456789" - static const int set_size = strlen(CHARSET); + const int set_size = strlen(CHARSET); l_getrandom(buf, len);