Description
In dcgmi the InstallCtrlHandler silently ignores the return codes in
.
Expected Behaviour
The return value of InstallCtrlHandler should be validated. If the installation fails, the code should:
- Log an error with sufficient context.
- Avoid continuing execution in an invalid state.
Actual Behavior
The function is invoked without checking its return value, so failures are ignored.
Why This Matters
Failing to install a control handler can prevent proper signal handling (e.g., shutdown, interrupts). Ignoring the result:
- Obscures root causes during failures.
- May lead to resource leaks or improper shutdown.
- Violates standard error-handling practices.
Description
In dcgmi the InstallCtrlHandler silently ignores the return codes in
DCGM/dcgmi/main_dcgmi.cpp
Line 78 in e137795
Expected Behaviour
The return value of InstallCtrlHandler should be validated. If the installation fails, the code should:
Actual Behavior
The function is invoked without checking its return value, so failures are ignored.
Why This Matters
Failing to install a control handler can prevent proper signal handling (e.g., shutdown, interrupts). Ignoring the result: