Avoid using common symbols in v850 libgloss

Mike Frysinger vapier@gentoo.org
Sun Mar 20 01:20:14 GMT 2022


On 09 Feb 2022 18:58, Jeff Law wrote:
> I've had this lying around for probably a year or two at this point.   
> It just changes all the instance of "errno" from a common symbol to an 
> extern.  I can't offhand recall where the actual definition is, but it 
> certainly exists in the generic code.
> 
> --- a/libgloss/v850/_exit.c
> +++ b/libgloss/v850/_exit.c
> @@ -3,7 +3,7 @@
>  #include <sys/stat.h>
>  #include "sys/syscall.h"
>  
> -int errno;
> +extern int errno;

why not just include errno.h ?  using `extern int errno;` is so pre-2000 :p.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/newlib/attachments/20220319/eafd7df5/attachment.sig>


More information about the Newlib mailing list