1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00

r10705: fixed a crash bug in the getdcname irpc server for winbind. The

problem was that the return string was declared as:

	[out] astring dcname

which means "this is a non-NULL string". The server code sometimes
returned NULL however (on getdc lookup failure), which caused the NDR
marshalling code to crash. When you declare a non-pointer return value
you are promising that the value can never be NULL.

The trivial fix is to use:

	[out] astring *dcname

which leaves the API alone, but includes a pointer in the wire format,
which in turn means it is valid to send a NULL string as a response.
(This used to be commit e39bac6196)
This commit is contained in:
Andrew Tridgell 2005-10-04 01:43:24 +00:00 committed by Gerald (Jerry) Carter
parent 2c3e4bdadf
commit 3a7e251f27

View File

@ -59,7 +59,7 @@
[in] astring my_accountname,
[in] uint32 account_control,
[in,ref] dom_sid *domain_sid,
[out] astring dcname
[out] astring *dcname
);
/******************************************************