Rearrange a bit.
[kopensolaris-gnu/glibc.git] / linuxthreads / errno.c
index 3619aa8..bd9584f 100644 (file)
 int * __errno_location()
 {
   pthread_descr self = thread_self();
-  return self->p_errnop;
+  return THREAD_GETMEM (self, p_errnop);
 }
 
 int * __h_errno_location()
 {
   pthread_descr self = thread_self();
-  return self->p_h_errnop;
+  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);
 }