From: Zdenek Kabelac <zkabelac@sourceware.org>
To: lvm-devel@redhat.com
Subject: main - cov: drop unneeded constness
Date: Fri, 9 Jun 2023 16:01:58 +0000 (GMT) [thread overview]
Message-ID: <20230609160158.0F60C3858D3C@sourceware.org> (raw)
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=4d648380484ecf58c33f92a84950bb0bf39424ef
Commit: 4d648380484ecf58c33f92a84950bb0bf39424ef
Parent: 17ee5df8576acf628d88fd6840ce55aa1388d6d1
Author: Zdenek Kabelac <zkabelac@redhat.com>
AuthorDate: Thu May 11 19:17:18 2023 +0200
Committer: Zdenek Kabelac <zkabelac@redhat.com>
CommitterDate: Fri Jun 9 18:01:16 2023 +0200
cov: drop unneeded constness
If we want to have const structure - use a const pointer to avoid,
however making individual members const make it only assingle
in construct time and we already violate this logic since
we memcpy into the structure - so drop these unnecessary consts...
---
daemons/lvmpolld/lvmpolld-data-utils.h | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/daemons/lvmpolld/lvmpolld-data-utils.h b/daemons/lvmpolld/lvmpolld-data-utils.h
index 96a27f1c8..eeae4137c 100644
--- a/daemons/lvmpolld/lvmpolld-data-utils.h
+++ b/daemons/lvmpolld/lvmpolld-data-utils.h
@@ -45,18 +45,18 @@ struct lvmpolld_lv {
* accessing following vars doesn't
* require struct lvmpolld_lv lock
*/
- struct lvmpolld_state *const ls;
+ struct lvmpolld_state *ls;
const enum poll_type type;
- const char *const lvid;
- const char *const lvmpolld_id;
- const char *const devicesfile;
- const char *const lvname; /* full vg/lv name */
+ const char *lvid;
+ const char *lvmpolld_id;
+ const char *devicesfile;
+ const char *lvname; /* full vg/lv name */
const unsigned pdtimeout; /* in seconds */
- const char *const sinterval;
- const char *const lvm_system_dir_env;
- struct lvmpolld_store *const pdst;
- const char *const *cmdargv;
- const char *const *cmdenvp;
+ const char *sinterval;
+ const char *lvm_system_dir_env;
+ struct lvmpolld_store *pdst;
+ const char **cmdargv;
+ const char **cmdenvp;
/* only used by write */
pid_t cmd_pid;
reply other threads:[~2023-06-09 16:01 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230609160158.0F60C3858D3C@sourceware.org \
--to=zkabelac@sourceware.org \
--cc=lvm-devel@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.