1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

gcc: remove warns about free of const

This commit is contained in:
Zdenek Kabelac 2018-02-13 19:53:07 +01:00
parent 0eb9daf602
commit c3642957c5
5 changed files with 7 additions and 7 deletions

View File

@ -531,7 +531,7 @@ static int _mirrored_modules_needed(struct dm_pool *mem,
static void _mirrored_destroy(struct segment_type *segtype)
{
dm_free(segtype->dso);
dm_free((void *) segtype->dso);
dm_free(segtype);
}

View File

@ -363,8 +363,8 @@ static int _raid_target_status_compatible(const char *type)
static void _raid_destroy(struct segment_type *segtype)
{
dm_free(segtype->dso);
dm_free((void *) segtype);
dm_free((void *) segtype->dso);
dm_free(segtype);
}
#ifdef DEVMAPPER_SUPPORT
@ -652,7 +652,7 @@ int init_multiple_segtypes(struct cmd_context *cmd, struct segtype_library *segl
#endif
{
struct segment_type *segtype;
const char *dso = NULL;
char *dso = NULL;
unsigned i;
uint64_t monitored = 0;

View File

@ -224,7 +224,7 @@ static int _snap_modules_needed(struct dm_pool *mem,
static void _snap_destroy(struct segment_type *segtype)
{
dm_free(segtype->dso);
dm_free((void *) segtype->dso);
dm_free(segtype);
}

View File

@ -745,7 +745,7 @@ static int _thin_target_present(struct cmd_context *cmd,
static void _thin_destroy(struct segment_type *segtype)
{
dm_free(segtype->dso);
dm_free((void *) segtype->dso);
dm_free(segtype);
}

View File

@ -49,7 +49,7 @@ static int _unknown_text_export(const struct lv_segment *seg, struct formatter *
static void _unknown_destroy(struct segment_type *segtype)
{
dm_free(segtype->name);
dm_free((void *) segtype->name);
dm_free(segtype);
}