Skip to content

sdr: Fix segfault on invalid unit types #120

Merged
merged 1 commit into from May 27, 2019

Conversation

AlexanderAmelkin
Copy link
Contributor

The program would crash if the BMC returned an out of range (>90)
unit type for a full sensor record. This commit adds a range check
and also add support for IPMI 2.0 additional unit types 91 and 92
("fatal error" and "grams").

Resolves #118

Signed-off-by: Alexander Amelkin alexander@amelkin.msk.ru

The program would crash if the BMC returned an out of range (>90)
unit type for a full sensor record. This commit adds a range check
and also add support for IPMI 2.0 additional unit types 91 and 92
("fatal error" and "grams").

Resolves #118

Signed-off-by: Alexander Amelkin <alexander@amelkin.msk.ru>
@leye7755
Copy link

#118 At present, I simply set the value beyond this range to 0.

@AlexanderAmelkin
Copy link
Contributor Author

@leye7755, does THIS patch work for you? Please build from this branch and tell me if it works:

# (assuming you're inside the cloned repo)
git checkout bugfix/118-fix-sdr-unit-segfault
./bootstrap
./configure
make

@AlexanderAmelkin AlexanderAmelkin merged commit 12e2f5d into master May 27, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working improvement Improves an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

encounter Segmentation fault when using ipmitool
2 participants