This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] prevent warnings while vompiling clib/syscalls


On 08/02/18 11:48, Jaap de Wolff wrote:
At this moment we get warnings while we compile the libc/syscalls folder.
This patch will prevent this

Jaap de Wolff
=======================PATCH===============================
diff --git a/newlib/libc/syscalls/sysisatty.c
b/newlib/libc/syscalls/sysisatty.c
index 697c54bc4..f4e8789ce 100644
--- a/newlib/libc/syscalls/sysisatty.c
+++ b/newlib/libc/syscalls/sysisatty.c
@@ -3,6 +3,11 @@
  #include <reent.h>
  #include <unistd.h>
+
+/* forward declaration */
+extern int _isatty_r(struct _reent *, int);
+extern int _isatty(int);
+
  int
  isatty (int fd)
  {

These functions are already conditionally defined in <reent.h>. Why do we need additional function declarations in source files?

--
Sebastian Huber, embedded brains GmbH

Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone   : +49 89 189 47 41-16
Fax     : +49 89 189 47 41-09
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]