Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 903480 Details for
Bug 926344
net-wireless/bluez-5.76-r1 - tools/hex2hcd.c:305:18: error: call to undeclared function 'basename'
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
hex2hcd fix
897.patch (text/plain), 1.19 KB, created by
Pablo Cholaky
on 2024-09-21 04:27:12 UTC
(
hide
)
Description:
hex2hcd fix
Filename:
MIME Type:
Creator:
Pablo Cholaky
Created:
2024-09-21 04:27:12 UTC
Size:
1.19 KB
patch
obsolete
>From e2f12111385dc4c21e2ef435025e1ddf8c386fa2 Mon Sep 17 00:00:00 2001 >From: Rahul Sandhu <rahul@sandhuservices.dev> >Date: Wed, 10 Jul 2024 11:12:30 +0100 >Subject: [PATCH] tools/hex2hcd: fix musl compatibility > >The call to basename() relies on a GNU extension >to take a const char * vs a char *. Let's define >a trivial helper function to ensure compatibility >with musl. > >Downstream gentoo bug: https://bugs.gentoo.org/926344 >Fixes: #843 >Signed-off-by: Rahul Sandhu <rahul@sandhuservices.dev> >--- > tools/hex2hcd.c | 7 ++++++- > 1 file changed, 6 insertions(+), 1 deletion(-) > >diff --git a/tools/hex2hcd.c b/tools/hex2hcd.c >index e6dca5a810..42c95b759b 100644 >--- a/tools/hex2hcd.c >+++ b/tools/hex2hcd.c >@@ -285,6 +285,11 @@ static void ver_parse_file(const char *pathname) > prev->next = ver; > } > >+static const char *helper_basename(const char *path) { >+ const char *base = strrchr(path, '/'); >+ return base ? base + 1 : path; >+} >+ > static void ver_parse_entry(const char *pathname) > { > struct stat st; >@@ -302,7 +307,7 @@ static void ver_parse_entry(const char *pathname) > } > > if (S_ISREG(st.st_mode)) { >- ver_parse_file(basename(pathname)); >+ ver_parse_file(helper_basename(pathname)); > goto done; > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 926344
:
886893
|
886894
|
892893
|
900108
|
903479
| 903480