From d8379c44d005917682fc8c4d6091e9a8e4d42150 Mon Sep 17 00:00:00 2001 From: Chris Guikema Date: Tue, 17 Sep 2024 10:10:50 -0400 Subject: [PATCH] usbdrivers, trivial: fix free error check ps_free will always return 0. Therefore, the error check was always triggering, causing a ZF_LOGF statement to trigger. Signed-off-by: Chris Guikema --- libusbdrivers/src/services.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libusbdrivers/src/services.h b/libusbdrivers/src/services.h index 274b5aa..7ee9764 100644 --- a/libusbdrivers/src/services.h +++ b/libusbdrivers/src/services.h @@ -41,7 +41,7 @@ static inline void usb_free(void *ptr) if (ps_malloc_ops && ps_malloc_ops->free) { ret = ps_free(ps_malloc_ops, 1, ptr); - if (!ret) { + if (ret != 0) { ZF_LOGF("Free error\n"); } } else {