From e1ab3c3470a7f1159d52ed0c1eacf4a5a7b6bc2b Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Tue, 28 Dec 2010 11:55:47 +0100 Subject: s3: Remove an ancient typedef --- nsswitch/wins.c | 6 +++--- source3/include/proto.h | 2 +- source3/include/smb.h | 4 ++-- source3/libsmb/namequery.c | 12 ++++++------ source3/utils/nmblookup.c | 2 +- source3/winbindd/winbindd_wins.c | 6 +++--- 6 files changed, 16 insertions(+), 16 deletions(-) diff --git a/nsswitch/wins.c b/nsswitch/wins.c index aa02f32ce1..731efcb448 100644 --- a/nsswitch/wins.c +++ b/nsswitch/wins.c @@ -162,12 +162,12 @@ static struct in_addr *lookup_byname_backend(const char *name, int *count) #ifdef HAVE_NS_API_H -static NODE_STATUS_STRUCT *lookup_byaddr_backend(char *addr, int *count) +static struct node_status *lookup_byaddr_backend(char *addr, int *count) { int fd; struct sockaddr_storage ss; struct nmb_name nname; - NODE_STATUS_STRUCT *status; + struct node_status *status; if (!initialised) { nss_wins_init(); @@ -202,7 +202,7 @@ int lookup(nsd_file_t *rq) char *key; char *addr; struct in_addr *ip_list; - NODE_STATUS_STRUCT *status; + struct node_status *status; int i, count, len, size; char response[1024]; bool found = False; diff --git a/source3/include/proto.h b/source3/include/proto.h index f9bf72f7a3..af2b359531 100644 --- a/source3/include/proto.h +++ b/source3/include/proto.h @@ -2699,7 +2699,7 @@ bool saf_store( const char *domain, const char *servername ); bool saf_join_store( const char *domain, const char *servername ); bool saf_delete( const char *domain ); char *saf_fetch( const char *domain ); -NODE_STATUS_STRUCT *node_status_query(int fd, +struct node_status *node_status_query(int fd, struct nmb_name *name, const struct sockaddr_storage *to_ss, int *num_names, diff --git a/source3/include/smb.h b/source3/include/smb.h index 8d12fb967d..1957504791 100644 --- a/source3/include/smb.h +++ b/source3/include/smb.h @@ -1687,11 +1687,11 @@ struct nmb_name { }; /* A netbios node status array element. */ -typedef struct node_status_ { +struct node_status { nstring name; unsigned char type; unsigned char flags; -} NODE_STATUS_STRUCT; +}; /* The extra info from a NetBIOS node status query */ struct node_status_extra { diff --git a/source3/libsmb/namequery.c b/source3/libsmb/namequery.c index e5eb75682e..e20945177e 100644 --- a/source3/libsmb/namequery.c +++ b/source3/libsmb/namequery.c @@ -212,11 +212,11 @@ static int generate_trn_id(void) Parse a node status response into an array of structures. ****************************************************************************/ -static NODE_STATUS_STRUCT *parse_node_status(char *p, +static struct node_status *parse_node_status(char *p, int *num_names, struct node_status_extra *extra) { - NODE_STATUS_STRUCT *ret; + struct node_status *ret; int i; *num_names = CVAL(p,0); @@ -224,7 +224,7 @@ static NODE_STATUS_STRUCT *parse_node_status(char *p, if (*num_names == 0) return NULL; - ret = SMB_MALLOC_ARRAY(NODE_STATUS_STRUCT,*num_names); + ret = SMB_MALLOC_ARRAY(struct node_status,*num_names); if (!ret) return NULL; @@ -278,7 +278,7 @@ static bool send_packet_request(struct packet_struct *p) structures holding the returned names or NULL if the query failed. **************************************************************************/ -NODE_STATUS_STRUCT *node_status_query(int fd, +struct node_status *node_status_query(int fd, struct nmb_name *name, const struct sockaddr_storage *to_ss, int *num_names, @@ -291,7 +291,7 @@ NODE_STATUS_STRUCT *node_status_query(int fd, struct packet_struct p; struct packet_struct *p2; struct nmb_packet *nmb = &p.packet.nmb; - NODE_STATUS_STRUCT *ret; + struct node_status *ret; ZERO_STRUCT(p); @@ -381,7 +381,7 @@ bool name_status_find(const char *q_name, { char addr[INET6_ADDRSTRLEN]; struct sockaddr_storage ss; - NODE_STATUS_STRUCT *status = NULL; + struct node_status *status = NULL; struct nmb_name nname; int count, i; int sock; diff --git a/source3/utils/nmblookup.c b/source3/utils/nmblookup.c index b63b0a38e5..e5cfe21806 100644 --- a/source3/utils/nmblookup.c +++ b/source3/utils/nmblookup.c @@ -113,7 +113,7 @@ static void do_node_status(int fd, { struct nmb_name nname; int count, i, j; - NODE_STATUS_STRUCT *status; + struct node_status *status; struct node_status_extra extra; fstring cleanname; char addr[INET6_ADDRSTRLEN]; diff --git a/source3/winbindd/winbindd_wins.c b/source3/winbindd/winbindd_wins.c index f5727cc9b7..1326fbc0a3 100644 --- a/source3/winbindd/winbindd_wins.c +++ b/source3/winbindd/winbindd_wins.c @@ -70,12 +70,12 @@ static int wins_lookup_open_socket_in(void) } -static NODE_STATUS_STRUCT *lookup_byaddr_backend(const char *addr, int *count) +static struct node_status *lookup_byaddr_backend(const char *addr, int *count) { int fd; struct sockaddr_storage ss; struct nmb_name nname; - NODE_STATUS_STRUCT *status; + struct node_status *status; fd = wins_lookup_open_socket_in(); if (fd == -1) @@ -147,7 +147,7 @@ void winbindd_wins_byip(struct winbindd_cli_state *state) { fstring response; int i, count, maxlen, size; - NODE_STATUS_STRUCT *status; + struct node_status *status; /* Ensure null termination */ state->request->data.winsreq[sizeof(state->request->data.winsreq)-1]='\0'; -- cgit