You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Added '-V' and '-F' option to the getopt_long() optstring.
- Marked -F/--freq option with required argument.
- Added NULL pointer checks to helper function arg_parse_freq().
Nightwalker-87
changed the title
[all]: st-util cannot parse -V and -F options and --freq option results in a segmentation fault.
st-util cannot parse -V and -F options and --freq option results in a segmentation fault
Oct 3, 2024
-V and -F options are not recognized on the command line of st-util program. When using --freq option a segmentation fault is the result.
examples:
$st-util -p 3333 -V --connect-under-reset --multi --semihosting -v99
st-util: invalid option -- 'V'
$st-util -p 3333 --connect-under-reset --multi --semihosting -v99 -F 2M
st-util: invalid option -- 'F'
non-option ARGV-elements: 2M
$st-util -p 3333 --connect-under-reset --multi --semihosting -v99 --freq 500k
st-util: Speicherzugriffsfehler
The reason is a bug in a getopt_long() parameters in main() function and missing NULL pointer security in arg_parse_freq() helper function.
See PR #1429
The text was updated successfully, but these errors were encountered: