From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot To: dri-devel-reviews@example.com Subject: Claude review: drm/ras: Cancel and free message on get counter failure Date: Sat, 16 May 2026 10:24:56 +1000 Message-ID: In-Reply-To: <20260514202839.1888688-2-raag.jadav@intel.com> References: <20260514202839.1888688-1-raag.jadav@intel.com> <20260514202839.1888688-2-raag.jadav@intel.com> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 Patch Review **Verdict: Good fix, ready to merge.** This correctly fixes a resource leak in `doit_reply_value()`. When `get_node_error_counter()` fails, the previously allocated `sk_buff` (`msg`) and the genetlink header (`hdr`) were leaked because the function returned early without cleanup. ```c if (ret) { genlmsg_cancel(msg, hdr); nlmsg_free(msg); return ret; } ``` This exactly mirrors the existing error handling for the `msg_reply_value()` failure path immediately below (lines 217-221 in the patched file). Clean, minimal, and correct. The Fixes tag is appropriate. --- --- Generated by Claude Code Patch Reviewer