mirror of
https://github.com/samba-team/samba.git
synced 2025-03-03 12:58:35 +03:00
Return NULL (instead of unchanged) for no shares/parameters defined.
Michael (This used to be commit bfe3d1462f52d2849611fc58ad70fa08b4917077)
This commit is contained in:
parent
a6d6fbb73d
commit
397b4d5397
@ -358,6 +358,9 @@ static WERROR libnet_smbconf_reg_get_values(TALLOC_CTX *mem_ctx,
|
|||||||
if (count > 0) {
|
if (count > 0) {
|
||||||
*value_names = talloc_move(mem_ctx, &tmp_valnames);
|
*value_names = talloc_move(mem_ctx, &tmp_valnames);
|
||||||
*value_strings = talloc_move(mem_ctx, &tmp_valstrings);
|
*value_strings = talloc_move(mem_ctx, &tmp_valstrings);
|
||||||
|
} else {
|
||||||
|
*value_names = NULL;
|
||||||
|
*value_strings = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
done:
|
done:
|
||||||
@ -486,6 +489,8 @@ WERROR libnet_smbconf_get_share_names(TALLOC_CTX *mem_ctx, uint32_t *num_shares,
|
|||||||
*num_shares = added_count;
|
*num_shares = added_count;
|
||||||
if (added_count > 0) {
|
if (added_count > 0) {
|
||||||
*share_names = talloc_move(mem_ctx, &tmp_share_names);
|
*share_names = talloc_move(mem_ctx, &tmp_share_names);
|
||||||
|
} else {
|
||||||
|
*share_names = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
done:
|
done:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user