mirror of
https://github.com/samba-team/samba.git
synced 2024-12-25 23:21:54 +03:00
fix crash bug in pidl generated client code, this
could have happend with [in,out,unique] pointers when the clients sends a valid pointer, but the server reponse with a NULL pointer (as samba-3.0.26a do for some calls). I've tested with midl to see how windows handles this situation and also the reverse case where the client sends NULL and the server reposnse with non-NULL. It appears that midl generated code just ignores this and only copies the result if both pointers are non-NULL. Note: this is just cosmetic for the 3.0.x tree, as rpccli_wkssvc_NetWkstaEnumUsers and rpccli_wkssvc_NetWkstaTransportEnum are not used. metze
This commit is contained in:
parent
d2a42b4b53
commit
f37f19f817
@ -102,10 +102,10 @@ NTSTATUS rpccli_wkssvc_NetWkstaEnumUsers(struct rpc_pipe_client *cli, TALLOC_CTX
|
||||
|
||||
/* Return variables */
|
||||
*users = *r.out.users;
|
||||
if ( entriesread ) {
|
||||
if (entriesread && r.out.entriesread) {
|
||||
*entriesread = *r.out.entriesread;
|
||||
}
|
||||
if ( totalentries ) {
|
||||
if (totalentries && r.out.totalentries) {
|
||||
*totalentries = *r.out.totalentries;
|
||||
}
|
||||
*resumehandle = *r.out.resumehandle;
|
||||
@ -203,7 +203,7 @@ NTSTATUS rpccli_wkssvc_NetWkstaTransportEnum(struct rpc_pipe_client *cli, TALLOC
|
||||
/* Return variables */
|
||||
*level = *r.out.level;
|
||||
*ctr = *r.out.ctr;
|
||||
if ( totalentries ) {
|
||||
if (totalentries && r.out.totalentries) {
|
||||
*totalentries = *r.out.totalentries;
|
||||
}
|
||||
*resume_handle = *r.out.resume_handle;
|
||||
|
Loading…
Reference in New Issue
Block a user