This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc 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]

FreeBSD port (38): avoid warnings in linuxthreads


When building with --enable-all-warnings, I get these warnings:

errno.c:24: warning: function declaration isn't a prototype
errno.c:37: warning: function declaration isn't a prototype

This fixes it.


linuxthreads/ChangeLog:
2002-09-04  Bruno Haible  <bruno@clisp.org>

	* errno.c (__errno_location, __h_errno_location, __res_state): Use
	prototype function declaration.

diff -r -c3 glibc-20020828.bak/linuxthreads/errno.c glibc-20020828/linuxthreads/errno.c
*** glibc-20020828.bak/linuxthreads/errno.c	Mon Aug  5 13:24:34 2002
--- glibc-20020828/linuxthreads/errno.c	Fri Aug 30 11:13:53 2002
***************
*** 23,42 ****
  
  #if !USE_TLS || !HAVE___THREAD
  /* The definition in libc is sufficient if we use TLS.  */
! int * __errno_location()
  {
    pthread_descr self = thread_self();
    return THREAD_GETMEM (self, p_errnop);
  }
  
! int * __h_errno_location()
  {
    pthread_descr self = thread_self();
    return THREAD_GETMEM (self, p_h_errnop);
  }
  
  /* Return thread specific resolver state.  */
! struct __res_state * __res_state()
  {
    pthread_descr self = thread_self();
    return THREAD_GETMEM (self, p_resp);
--- 23,45 ----
  
  #if !USE_TLS || !HAVE___THREAD
  /* The definition in libc is sufficient if we use TLS.  */
! int *
! __errno_location (void)
  {
    pthread_descr self = thread_self();
    return THREAD_GETMEM (self, p_errnop);
  }
  
! int *
! __h_errno_location (void)
  {
    pthread_descr self = thread_self();
    return THREAD_GETMEM (self, p_h_errnop);
  }
  
  /* Return thread specific resolver state.  */
! struct __res_state *
! __res_state (void)
  {
    pthread_descr self = thread_self();
    return THREAD_GETMEM (self, p_resp);


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