summaryrefslogtreecommitdiff
path: root/source3/libnet
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2008-01-12 01:28:20 +0100
committerGünther Deschner <gd@samba.org>2008-01-12 01:36:04 +0100
commit8921b2222a9e2db9e185486b247fb5fca448971d (patch)
treef78c0a7a7c08e4eae24d4343344a56d8c8697ce7 /source3/libnet
parent9d164c409442c54a17791865b77f6b5b3d136d80 (diff)
downloadsamba-8921b2222a9e2db9e185486b247fb5fca448971d.tar.gz
samba-8921b2222a9e2db9e185486b247fb5fca448971d.tar.bz2
samba-8921b2222a9e2db9e185486b247fb5fca448971d.zip
Auto-add missing shares in libnet_conf_set_parameter().
Michael, please have a look. Guenther (This used to be commit 9f4506e5e2828e0f23bc37586770995c3424b208)
Diffstat (limited to 'source3/libnet')
-rw-r--r--source3/libnet/libnet_conf.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/libnet/libnet_conf.c b/source3/libnet/libnet_conf.c
index 0bdf4805d7..47b4800d80 100644
--- a/source3/libnet/libnet_conf.c
+++ b/source3/libnet/libnet_conf.c
@@ -719,8 +719,10 @@ WERROR libnet_conf_set_parameter(const char *service,
TALLOC_CTX *mem_ctx = talloc_stackframe();
if (!libnet_conf_share_exists(service)) {
- werr = WERR_NO_SUCH_SERVICE;
- goto done;
+ werr = libnet_conf_create_share(service);
+ if (!W_ERROR_IS_OK(werr)) {
+ goto done;
+ }
}
werr = libnet_conf_reg_open_service_key(mem_ctx, service, REG_KEY_WRITE,