Skip to content
Snippets Groups Projects
Commit 6b1cf128 authored by znley's avatar znley Committed by Andy Postnikov
Browse files

community/stlink: fix build with gcc14

parent 921fd55a
No related branches found
No related tags found
1 merge request!70474community/stlink: fix build with gcc14
Pipeline #253521 skipped
......@@ -11,6 +11,7 @@ makedepends="cmake libusb-dev samurai"
options="!check" # upstream doesn't have automated tests
subpackages="$pkgname-doc $pkgname-dev"
source="$pkgname-$pkgver.tar.gz::https://github.com/stlink-org/stlink/archive/v$pkgver.tar.gz
gcc14.patch
"
build() {
......@@ -38,4 +39,5 @@ package() {
sha512sums="
49245a4b0aeb926dd71ec4260b707d900318fe68e3a36e2e5543587fefb4886a9ff0ff42e0e12a8e727a5d4e9c7b4ce13989ca4d963842dbf960065e5fa0c968 stlink-1.8.0.tar.gz
f0374641756981c94d865d282cbe8009ccc9e9b41499501310f7442878e68b1984418428d13a7ea1f22312d5c928ec7bdb845d99a54a4264497a954859ad38cc gcc14.patch
"
diff --git a/src/stlink-lib/chipid.c b/src/stlink-lib/chipid.c
index c115089..0a6a4e9 100644
--- a/src/stlink-lib/chipid.c
+++ b/src/stlink-lib/chipid.c
@@ -65,7 +65,7 @@ void process_chipfile(char *fname) {
return;
}
- ts = calloc(sizeof(struct stlink_chipid_params), 1);
+ ts = calloc(1, sizeof(struct stlink_chipid_params));
while (fgets(buf, sizeof(buf), fp) != NULL) {
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment