From 82769bcc8fc459c00df7074578de5f0daac8a858 Mon Sep 17 00:00:00 2001 From: dd86k Date: Mon, 30 Dec 2024 13:25:16 -0500 Subject: [PATCH] objectserver: Use calloc instead --- src/adbg/objectserver.d | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/adbg/objectserver.d b/src/adbg/objectserver.d index d634853..7f4df31 100644 --- a/src/adbg/objectserver.d +++ b/src/adbg/objectserver.d @@ -200,7 +200,7 @@ export adbg_object_t* adbg_object_open_file(const(char) *path, ...) { version (Trace) trace("path=%s", path); - adbg_object_t *o = cast(adbg_object_t*)malloc(adbg_object_t.sizeof); + adbg_object_t *o = cast(adbg_object_t*)calloc(1, adbg_object_t.sizeof); if (o == null) { adbg_oops(AdbgError.crt); return null;