From: Mike Frysinger <vapier@gentoo.org>
To: newlib@sourceware.org
Subject: [PATCH/committed] libgloss: bfin: fix various warnings
Date: Sat, 12 Feb 2022 01:35:55 -0500 [thread overview]
Message-ID: <20220212063555.23074-1-vapier@gentoo.org> (raw)
No functional changes here, just fix warnings the compiler noticed.
bfin/syscalls.c:156:13: warning: conflicting types for built-in function ‘memset’
bfin/syscalls.c: In function ‘_unlink’:
bfin/syscalls.c:193:3: warning: passing argument 2 of ‘do_syscall’ discards qualifiers from pointer target type
bfin/syscalls.c:33:1: note: expected ‘void *’ but argument is of type ‘const char *’
bfin/syscalls.c: In function ‘_exit’:
bfin/syscalls.c:104:1: warning: ‘noreturn’ function does return
---
libgloss/bfin/syscalls.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/libgloss/bfin/syscalls.c b/libgloss/bfin/syscalls.c
index 2dea8c59873d..7bd0bede189d 100644
--- a/libgloss/bfin/syscalls.c
+++ b/libgloss/bfin/syscalls.c
@@ -101,6 +101,7 @@ void
_exit (int n)
{
do_syscall (SYS_exit, &n);
+ __builtin_unreachable ();
}
int
@@ -153,7 +154,7 @@ _sbrk (int incr)
return (caddr_t) prev_heap_end;
}
-extern void memset (struct stat *, int, unsigned int);
+extern void *memset (void *, int, unsigned int);
int
_fstat (int file, struct stat *st)
@@ -190,7 +191,7 @@ _link (const char *existing, const char *new)
int
_unlink (const char *path)
{
- return do_syscall (SYS_unlink, path);
+ return do_syscall (SYS_unlink, (char *) path);
}
void
--
2.34.1
reply other threads:[~2022-02-12 6:35 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220212063555.23074-1-vapier@gentoo.org \
--to=vapier@gentoo.org \
--cc=newlib@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).