summaryrefslogtreecommitdiff
path: root/source3/utils
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2011-04-07 17:19:03 +0200
committerMichael Adam <obnox@samba.org>2011-05-10 19:13:20 +0200
commit29eea4b09ad2e99504f42a3c29195fb4757792dd (patch)
tree97bff20a1b7977b07e0576960cb1b3b4830dbec0 /source3/utils
parentb34e1768b762ae46e4fe761d9691ed09d285c9a9 (diff)
downloadsamba-29eea4b09ad2e99504f42a3c29195fb4757792dd.tar.gz
samba-29eea4b09ad2e99504f42a3c29195fb4757792dd.tar.bz2
samba-29eea4b09ad2e99504f42a3c29195fb4757792dd.zip
libsmbconf: Convert smbconf_init() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
Diffstat (limited to 'source3/utils')
-rw-r--r--source3/utils/net_conf.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/source3/utils/net_conf.c b/source3/utils/net_conf.c
index fd00c008dd..9ed19f1fdb 100644
--- a/source3/utils/net_conf.c
+++ b/source3/utils/net_conf.c
@@ -316,6 +316,7 @@ static int net_conf_import(struct net_context *c, struct smbconf_ctx *conf_ctx,
TALLOC_CTX *mem_ctx;
struct smbconf_ctx *txt_ctx;
WERROR werr;
+ sbcErr err;
if (c->display_usage)
return net_conf_import_usage(c, argc, argv);
@@ -347,10 +348,11 @@ static int net_conf_import(struct net_context *c, struct smbconf_ctx *conf_ctx,
goto done;
}
- werr = smbconf_init(mem_ctx, &txt_ctx, conf_source);
- if (!W_ERROR_IS_OK(werr)) {
+ err = smbconf_init(mem_ctx, &txt_ctx, conf_source);
+ if (!SBC_ERROR_IS_OK(err)) {
d_printf(_("error loading file '%s': %s\n"), filename,
- win_errstr(werr));
+ sbcErrorString(err));
+ werr = WERR_NO_SUCH_SERVICE;
goto done;
}
@@ -1140,14 +1142,13 @@ static int net_conf_wrap_function(struct net_context *c,
int, const char **),
int argc, const char **argv)
{
- WERROR werr;
+ sbcErr err;
TALLOC_CTX *mem_ctx = talloc_stackframe();
struct smbconf_ctx *conf_ctx;
int ret = -1;
- werr = smbconf_init(mem_ctx, &conf_ctx, "registry:");
-
- if (!W_ERROR_IS_OK(werr)) {
+ err = smbconf_init(mem_ctx, &conf_ctx, "registry:");
+ if (!SBC_ERROR_IS_OK(err)) {
return -1;
}