summaryrefslogtreecommitdiff
path: root/resolv
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-12-30 08:09:32 +0000
committerUlrich Drepper <drepper@redhat.com>1999-12-30 08:09:32 +0000
commit66ac0abe0341c5b3b1189c0ef9805ac931aecf6e (patch)
tree4871f21f421ea16d19ab5ee4ea6ca1ccec448996 /resolv
parentd876f5327985eac3bf3109e9429febc8a8954ff5 (diff)
Update.
1999-12-13 Andreas Jaeger <aj@suse.de> * resolv/resolv.h: Remove K&R compatibility. * resolv/res_libc.c: Move definition of _res after res_init, res_init should use the threaded specific context. * resolv/Makefile (+cflags): Remove -Wno-comment since it's not needed anymore. * locale/langinfo.h: Add constants for wide character collation data. * locale/categories.def: Add appropriate entries for collate entries. * locale/C-collate.c: Add initializers for new entries. * locale/programs/ld-collate.c: Implement output of wide character tables. * locale/programs/ld-ctype.c (allocate_arrays): Change algorithm to compute wide character table size a bit: it now gives up a bit of total table size for fewer levels.
Diffstat (limited to 'resolv')
-rw-r--r--resolv/Makefile2
-rw-r--r--resolv/res_libc.c8
-rw-r--r--resolv/resolv.h52
3 files changed, 32 insertions, 30 deletions
diff --git a/resolv/Makefile b/resolv/Makefile
index c8dc54a80c..e853165511 100644
--- a/resolv/Makefile
+++ b/resolv/Makefile
@@ -57,7 +57,7 @@ CPPFLAGS += -Dgethostbyname=res_gethostbyname \
-Dgetnetbyaddr=res_getnetbyaddr
# The BIND code elicits some harmless warnings.
-+cflags += -Wno-strict-prototypes -Wno-comment -Wno-write-strings
++cflags += -Wno-strict-prototypes -Wno-write-strings
# Depend on libc.so so a DT_NEEDED is generated in the shared objects.
# This ensures they will load libc.so for needed symbols if loaded by
diff --git a/resolv/res_libc.c b/resolv/res_libc.c
index 14d565df0d..b83c27aaae 100644
--- a/resolv/res_libc.c
+++ b/resolv/res_libc.c
@@ -38,9 +38,6 @@ static const char rcsid[] = "$Id$";
#include <string.h>
#include <unistd.h>
-#undef _res
-
-struct __res_state _res;
/* This is the old res_init function. It has been moved from
res_data.c to this file since res_init should go into libc.so but
@@ -90,6 +87,11 @@ res_init(void) {
/* We need a resolver context - in unthreaded apps, this weak function
provides it. */
+#undef _res
+
+struct __res_state _res;
+
+
struct __res_state *
weak_const_function
__res_state(void)
diff --git a/resolv/resolv.h b/resolv/resolv.h
index b101262f51..eadacaef3e 100644
--- a/resolv/resolv.h
+++ b/resolv/resolv.h
@@ -136,19 +136,19 @@ struct __res_state; /* forward */
typedef enum { res_goahead, res_nextns, res_modified, res_done, res_error }
res_sendhookact;
-typedef res_sendhookact (*res_send_qhook)__P((struct sockaddr_in * const *ns,
- const u_char **query,
- int *querylen,
- u_char *ans,
- int anssiz,
- int *resplen));
+typedef res_sendhookact (*res_send_qhook) (struct sockaddr_in * const *ns,
+ const u_char **query,
+ int *querylen,
+ u_char *ans,
+ int anssiz,
+ int *resplen);
-typedef res_sendhookact (*res_send_rhook)__P((const struct sockaddr_in *ns,
- const u_char *query,
- int querylen,
- u_char *ans,
- int anssiz,
- int *resplen));
+typedef res_sendhookact (*res_send_rhook) (const struct sockaddr_in *ns,
+ const u_char *query,
+ int querylen,
+ u_char *ans,
+ int anssiz,
+ int *resplen);
struct res_sym {
int number; /* Identifying number, like T_MX */
@@ -270,20 +270,20 @@ extern struct __res_state _res;
#define res_send __res_send
__BEGIN_DECLS
-void fp_nquery __P((const u_char *, int, FILE *));
-void fp_query __P((const u_char *, FILE *));
-const char * hostalias __P((const char *));
-void p_query __P((const u_char *));
-void res_close __P((void));
-int res_init __P((void));
-int res_isourserver __P((const struct sockaddr_in *));
-int res_mkquery __P((int, const char *, int, int, const u_char *,
- int, const u_char *, u_char *, int));
-int res_query __P((const char *, int, int, u_char *, int));
-int res_querydomain __P((const char *, const char *, int, int,
- u_char *, int));
-int res_search __P((const char *, int, int, u_char *, int));
-int res_send __P((const u_char *, int, u_char *, int));
+void fp_nquery (const u_char *, int, FILE *) __THROW;
+void fp_query (const u_char *, FILE *) __THROW;
+const char * hostalias (const char *) __THROW;
+void p_query (const u_char *) __THROW;
+void res_close (void) __THROW;
+int res_init (void) __THROW;
+int res_isourserver (const struct sockaddr_in *) __THROW;
+int res_mkquery (int, const char *, int, int, const u_char *,
+ int, const u_char *, u_char *, int) __THROW;
+int res_query (const char *, int, int, u_char *, int) __THROW;
+int res_querydomain (const char *, const char *, int, int,
+ u_char *, int) __THROW;
+int res_search (const char *, int, int, u_char *, int) __THROW;
+int res_send (const u_char *, int, u_char *, int) __THROW;
__END_DECLS
#if !defined(SHARED_LIBBIND) || defined(_LIBC)