Ticket 21729

Summary: Memory Leak in slurm_free_job_step_info_members
Product: Slurm Reporter: Toni <toni.harzendorf>
Component: OtherAssignee: Jacob Jenson <jacob>
Status: OPEN --- QA Contact:
Severity: 6 - No support contract    
Priority: ---    
Version: 24.11.0   
Hardware: Linux   
OS: Linux   
Site: -Other- Alineos Sites: ---
Atos/Eviden Sites: --- Confidential Site: ---
Coreweave sites: --- Cray Sites: ---
DS9 clusters: --- Google sites: ---
HPCnow Sites: --- HPE Sites: ---
IBM Sites: --- NOAA SIte: ---
NoveTech Sites: --- Nvidia HWinf-CS Sites: ---
OCF Sites: --- Recursion Pharma Sites: ---
SFW Sites: --- SNIC sites: ---
Tzag Elita Sites: --- Linux Distro: ---
Machine Name: CLE Version:
Version Fixed: Target Release: ---
DevPrio: --- Emory-Cloud Sites: ---

Description Toni 2024-12-31 02:02:43 MST
Hi,

in Slurm >= 24.05, on tag slurm-24-11-0-1 at _unpack_job_step_info_members with a protocol version above 23.11, the value of "submit_line" for a step is unpacked:

https://github.com/SchedMD/slurm/blob/00a43d9e72a90f61547835ac9490f97669221322/src/common/slurm_protocol_pack.c#L3153

However, in slurm_free_job_step_info_members, this value is missing in the list and never freed, therefore leading to a small memory leak:

https://github.com/SchedMD/slurm/blob/00a43d9e72a90f61547835ac9490f97669221322/src/common/slurm_protocol_defs.c#L4185

Also on master this value is still not yet in the list of members to be freed.
When I manually recreated the slurm_free_job_step_info_response_msg function, which also calls slurm_free_job_step_info_members, and manually free "submit_line", then everything is fine.

Best Regards and Happy new Year,
Toni