summaryrefslogtreecommitdiffstats
path: root/source4/libcli/nbt/libnbt.h
diff options
context:
space:
mode:
Diffstat (limited to 'source4/libcli/nbt/libnbt.h')
-rw-r--r--source4/libcli/nbt/libnbt.h16
1 files changed, 10 insertions, 6 deletions
diff --git a/source4/libcli/nbt/libnbt.h b/source4/libcli/nbt/libnbt.h
index 5a53510ccf..218b5e5921 100644
--- a/source4/libcli/nbt/libnbt.h
+++ b/source4/libcli/nbt/libnbt.h
@@ -31,6 +31,12 @@ enum nbt_request_state {NBT_REQUEST_SEND,
NBT_REQUEST_TIMEOUT,
NBT_REQUEST_ERROR};
+/* where to send the request/replies */
+struct nbt_peer_socket {
+ const char *addr;
+ int port;
+};
+
/*
a nbt name request
*/
@@ -45,8 +51,7 @@ struct nbt_name_request {
struct nbt_name_socket *nbtsock;
/* where to send the request */
- const char *dest_addr;
- int dest_port;
+ struct nbt_peer_socket dest;
/* timeout between retries */
int timeout;
@@ -75,8 +80,7 @@ struct nbt_name_request {
uint_t num_replies;
struct nbt_name_reply {
struct nbt_name_packet *packet;
- const char *reply_addr;
- int reply_port;
+ struct nbt_peer_socket dest;
} *replies;
/* information on what to do on completion */
@@ -110,14 +114,14 @@ struct nbt_name_socket {
/* what to do with incoming request packets */
struct {
void (*handler)(struct nbt_name_socket *, struct nbt_name_packet *,
- const char *, int );
+ const struct nbt_peer_socket *);
void *private;
} incoming;
/* what to do with unexpected replies */
struct {
void (*handler)(struct nbt_name_socket *, struct nbt_name_packet *,
- const char *, int );
+ const struct nbt_peer_socket *);
void *private;
} unexpected;
};