From a00e024f62818abdedf17fdf87508b237798c2e3 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Mon, 18 Nov 2024 13:08:29 -0800 Subject: [PATCH] drd: Reorder functions Reorder two functions such that a forward declaration can be removed. --- drd/drd_clientreq.c | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) diff --git a/drd/drd_clientreq.c b/drd/drd_clientreq.c index 8a462253d..2f30cb794 100644 --- a/drd/drd_clientreq.c +++ b/drd/drd_clientreq.c @@ -46,22 +46,8 @@ Bool DRD_(g_free_is_write); -/* Local function declarations. */ - -static Bool handle_client_request(ThreadId vg_tid, UWord* arg, UWord* ret); - - /* Function definitions. */ -/** - * Tell the Valgrind core the address of the DRD function that processes - * client requests. Must be called before any client code is run. - */ -void DRD_(clientreq_init)(void) -{ - VG_(needs_client_requests)(handle_client_request); -} - /** * DRD's handler for Valgrind client requests. The code below handles both * DRD's public and tool-internal client requests. @@ -636,3 +622,12 @@ static Bool handle_client_request(ThreadId vg_tid, UWord* arg, UWord* ret) *ret = result; return True; } + +/** + * Tell the Valgrind core the address of the DRD function that processes + * client requests. Must be called before any client code is run. + */ +void DRD_(clientreq_init)(void) +{ + VG_(needs_client_requests)(handle_client_request); +} -- 2.47.2