diff options
-rw-r--r-- | source/nmbd/nmbd_namelistdb.c | 1 | ||||
-rw-r--r-- | source/nmbd/nmbd_nameregister.c | 6 |
2 files changed, 4 insertions, 3 deletions
diff --git a/source/nmbd/nmbd_namelistdb.c b/source/nmbd/nmbd_namelistdb.c index f9cbcf4f59a..6570fd4ec76 100644 --- a/source/nmbd/nmbd_namelistdb.c +++ b/source/nmbd/nmbd_namelistdb.c @@ -297,7 +297,6 @@ void standard_success_register(struct subnet_record *subrec, ******************************************************************/ void standard_fail_register( struct subnet_record *subrec, - struct response_record *rrec, struct nmb_name *nmbname ) { struct name_record *namerec; diff --git a/source/nmbd/nmbd_nameregister.c b/source/nmbd/nmbd_nameregister.c index edcf258519b..98f129aa892 100644 --- a/source/nmbd/nmbd_nameregister.c +++ b/source/nmbd/nmbd_nameregister.c @@ -152,10 +152,11 @@ static void register_name_response(struct subnet_record *subrec, if( rrec->success_fn) (*(register_name_success_function)rrec->success_fn)(subrec, rrec->userdata, answer_name, nb_flags, ttl, register_ip); } else { + struct nmb_name qname = *question_name; if( rrec->fail_fn) (*(register_name_fail_function)rrec->fail_fn)(subrec, rrec, question_name); /* Remove the name. */ - standard_fail_register( subrec, rrec, question_name); + standard_fail_register( subrec, &qname); } /* Ensure we don't retry. */ @@ -280,10 +281,11 @@ static void register_name_timeout_response(struct subnet_record *subrec, if( rrec->success_fn) (*(register_name_success_function)rrec->success_fn)(subrec, rrec->userdata, question_name, nb_flags, ttl, registered_ip); } else { + struct nmb_name qname = *question_name; if( rrec->fail_fn) (*(register_name_fail_function)rrec->fail_fn)(subrec, rrec, question_name); /* Remove the name. */ - standard_fail_register( subrec, rrec, question_name); + standard_fail_register( subrec, &qname); } /* Ensure we don't retry. */ |