Ticket 10531

Summary: Uninitialized variable in _rpc_file_bcast
Product: Slurm Reporter: Alex Henrie <alexhenrie24>
Component: slurmdAssignee: Tim Wickberg <tim>
Status: RESOLVED FIXED QA Contact:
Severity: C - Contributions    
Priority: ---    
Version: 21.08.x   
Hardware: Linux   
OS: Linux   
Site: University of Utah Alineos Sites: ---
Atos/Eviden Sites: --- Confidential Site: ---
Coreweave sites: --- Cray Sites: ---
DS9 clusters: --- HPCnow Sites: ---
HPE Sites: --- IBM Sites: ---
NOAA SIte: --- OCF Sites: ---
Recursion Pharma Sites: --- SFW Sites: ---
SNIC sites: --- Linux Distro: ---
Machine Name: CLE Version:
Version Fixed: 20.11.3 Target Release: ---
DevPrio: --- Emory-Cloud Sites: ---
Attachments: Proposed patch

Description Alex Henrie 2020-12-31 14:30:22 MST
Currently _rpc_file_bcast only initializes rc on error paths, then passes it to slurm_send_rc_msg. This could cause an error to be reported when in fact there is no error.

Bug identified by scan-build <https://clang-analyzer.llvm.org/scan-build.html>
Comment 1 Alex Henrie 2020-12-31 14:31:12 MST
Created attachment 17308 [details]
Proposed patch

The attached patch fixes the problem.
Comment 2 Tim Wickberg 2021-01-04 10:34:59 MST
Comment on attachment 17308 [details]
Proposed patch

commit 6193b149712d688abb8714ad4c1afe90065da643
Author:     Alex Henrie <alexhenrie24@gmail.com>
AuthorDate: Thu Dec 31 14:30:37 2020 -0700

    Fix uninitialized variable in _rpc_file_bcast().
    
    Bug 10531.
Comment 3 Tim Wickberg 2021-01-04 10:35:32 MST
Thanks Alex. This will be included in 20.11.3 when released.

- Tim
Comment 4 Alex Henrie 2021-01-04 14:47:36 MST
Thank you!