-
-
Notifications
You must be signed in to change notification settings - Fork 14.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
stlink: patch incorrect calloc argument order #368703
Conversation
f2e95a7
to
201cbb9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! One nitpick: can you "fetchpatch" the patch instead?
201cbb9
to
6bd5697
Compare
I'm not sure what you had in mind to be honest. I could also use their commits, but I was worried that might break something since I don’t know what has changed between |
I thought the local patch was exported from the upstream git repo, but I see now that it isn't. Sorry for the confusion -- I think your original commit is fine. |
6bd5697
to
f81202a
Compare
With the update to GCC 14, stlink v1.8.0 is broken, as GCC 14 enforces the correct argument order of calloc. This commit adds a little patch to resolve that issue for now. This patch should be removed and stlink updated to v1.8.1 as soon as that version gets released.
f81202a
to
4619390
Compare
What do you think of this solution? It uses their commit and just pulls the file containing the swapped calloc arguments. I think I like this solution the best. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect, thanks!
With the update to GCC 14,
stlink v1.8.0
is broken, as GCC 14 enforces the correct argument order of calloc (-Wcalloc-transposed-args
). This commit adds a little patch to resolve the issue for now. This patch should be removed and stlink updated to the newest version that gets released. I've opened an issue in the stlink repository and am waiting for their response stlink-org/stlink#1444.I have only performed minimal testing on the binaries, but I’d be very surprised if this patch causes any negative side effects.
Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.