summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source4/libcli/nbt/nbtsocket.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source4/libcli/nbt/nbtsocket.c b/source4/libcli/nbt/nbtsocket.c
index 8b212fb555..b0248b6de0 100644
--- a/source4/libcli/nbt/nbtsocket.c
+++ b/source4/libcli/nbt/nbtsocket.c
@@ -345,10 +345,12 @@ struct nbt_name_request *nbt_name_request_send(struct nbt_name_socket *nbtsock,
id = idr_get_new_above(req->nbtsock->idr, req,
req->request->name_trn_id, UINT16_MAX);
if (id == -1) {
- id = idr_get_new_above(req->nbtsock->idr, req, 1+(generate_random()%(UINT16_MAX/2)),
+ id = idr_get_new_above(req->nbtsock->idr, req,
+ 1+(generate_random()%(UINT16_MAX/2)),
UINT16_MAX);
}
if (id == -1) goto failed;
+ req->request->name_trn_id = id;
te.next_event = timeout;
te.handler = nbt_name_socket_timeout;