diff options
author | Rikard Falkeborn <rikard.falkeborn@gmail.com> | 2021-09-22 00:21:03 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2021-09-23 12:54:35 +0200 |
commit | e75be2c4b20ced981606c1338759ac3dc6edc309 (patch) | |
tree | b6baf0713f1d44c01c6de12b423f2b2f3b877f31 /lib | |
parent | c7aef0a945f9b6fb6d3f91716a21dfe2f4ea635f (diff) | |
download | curl-e75be2c4b20ced981606c1338759ac3dc6edc309.tar.gz |
cleanup: constify unmodified static structs
Constify a number of static structs that are never modified. Make them
const to show this.
Closes #7759
Diffstat (limited to 'lib')
-rw-r--r-- | lib/krb5.c | 2 | ||||
-rw-r--r-- | lib/multi.c | 2 | ||||
-rw-r--r-- | lib/splay.c | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/lib/krb5.c b/lib/krb5.c index e25f52656..bb2930151 100644 --- a/lib/krb5.c +++ b/lib/krb5.c @@ -374,7 +374,7 @@ static void krb5_end(void *app_data) } } -static struct Curl_sec_client_mech Curl_krb5_client_mech = { +static const struct Curl_sec_client_mech Curl_krb5_client_mech = { "GSSAPI", sizeof(gss_ctx_id_t), krb5_init, diff --git a/lib/multi.c b/lib/multi.c index 518ceb51f..68c1a64d5 100644 --- a/lib/multi.c +++ b/lib/multi.c @@ -3180,7 +3180,7 @@ CURLMcode curl_multi_socket_all(struct Curl_multi *multi, int *running_handles) static CURLMcode multi_timeout(struct Curl_multi *multi, long *timeout_ms) { - static struct curltime tv_zero = {0, 0}; + static const struct curltime tv_zero = {0, 0}; if(multi->timetree) { /* we have a tree of expire times */ diff --git a/lib/splay.c b/lib/splay.c index a94e2c85e..1c1dafb92 100644 --- a/lib/splay.c +++ b/lib/splay.c @@ -154,7 +154,7 @@ struct Curl_tree *Curl_splaygetbest(struct curltime i, struct Curl_tree *t, struct Curl_tree **removed) { - static struct curltime tv_zero = {0, 0}; + static const struct curltime tv_zero = {0, 0}; struct Curl_tree *x; if(!t) { |