From c41cf6fdf514fce6b69f8f875b6903b2a3910f89 Mon Sep 17 00:00:00 2001 From: Palmer Dabbelt Date: Mon, 3 Apr 2017 09:03:57 -0700 Subject: [PATCH] RISC-V: Avoid a const warning 2017-04-03 Palmer Dabbelt * config/tc-riscv.c (riscv_clear_subsets): Cast argument to free to avoid const warnings. --- gas/ChangeLog | 5 +++++ gas/config/tc-riscv.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/gas/ChangeLog b/gas/ChangeLog index 169b2ff68d4..557b43cc5ec 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,8 @@ +2017-04-03 Palmer Dabbelt + + * config/tc-riscv.c (riscv_clear_subsets): Cast argument to free to + avoid const warnings. + 2017-03-30 Palmer Dabbelt * config/tc-riscv.c (riscv_clear_subsets): New function. diff --git a/gas/config/tc-riscv.c b/gas/config/tc-riscv.c index 2830ba1e53e..0a9817a3201 100644 --- a/gas/config/tc-riscv.c +++ b/gas/config/tc-riscv.c @@ -126,7 +126,7 @@ riscv_clear_subsets (void) while (riscv_subsets != NULL) { struct riscv_subset *next = riscv_subsets->next; - free (riscv_subsets->name); + free ((void *) riscv_subsets->name); free (riscv_subsets); riscv_subsets = next; } -- 2.30.2