From 0a553c12c71d5627abf223a926ab9688a5573f54 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Fri, 23 Sep 2022 14:00:24 +0200 Subject: Drop useless casts from g_malloc() & friends to pointer These memory allocation functions return void *, and casting to another pointer type is useless clutter. Drop these casts. If you really want another pointer type, consider g_new(). Signed-off-by: Markus Armbruster Reviewed-by: Laurent Vivier Message-Id: <20220923120025.448759-3-armbru@redhat.com> Signed-off-by: Laurent Vivier --- target/s390x/kvm/kvm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'target/s390x') diff --git a/target/s390x/kvm/kvm.c b/target/s390x/kvm/kvm.c index 508c24c..da8c47f 100644 --- a/target/s390x/kvm/kvm.c +++ b/target/s390x/kvm/kvm.c @@ -1033,7 +1033,7 @@ int kvm_arch_remove_hw_breakpoint(target_ulong addr, } size = nb_hw_breakpoints * sizeof(struct kvm_hw_breakpoint); hw_breakpoints = - (struct kvm_hw_breakpoint *)g_realloc(hw_breakpoints, size); + g_realloc(hw_breakpoints, size); } else { g_free(hw_breakpoints); hw_breakpoints = NULL; -- cgit v1.1