[SCM] Samba Shared Repository - branch v3-2-test updated -
initial-v3-2-unstable-1275-g1ad7a0a
Günther Deschner
gd at samba.org
Fri Jan 11 14:29:05 GMT 2008
The branch, v3-2-test has been updated
via 1ad7a0a361edfa5ac738f011db1d6a9db256ac2c (commit)
from 9cc0d874f6c064e8752d36e72fcc85bf4c85e656 (commit)
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-2-test
- Log -----------------------------------------------------------------
commit 1ad7a0a361edfa5ac738f011db1d6a9db256ac2c
Author: Günther Deschner <gd at samba.org>
Date: Fri Jan 11 15:28:24 2008 +0100
Fix libnetapi error string callers.
Guenther
-----------------------------------------------------------------------
Summary of changes:
source/lib/netapi/examples/getdc/getdc.c | 2 +-
.../examples/netdomjoin-gui/netdomjoin-gui.c | 8 ++++----
source/lib/netapi/examples/netdomjoin/netdomjoin.c | 4 ++--
source/utils/net_dom.c | 4 ++--
4 files changed, 9 insertions(+), 9 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source/lib/netapi/examples/getdc/getdc.c b/source/lib/netapi/examples/getdc/getdc.c
index 4f5c533..cdd4d0b 100644
--- a/source/lib/netapi/examples/getdc/getdc.c
+++ b/source/lib/netapi/examples/getdc/getdc.c
@@ -46,7 +46,7 @@ int main(int argc, char **argv)
status = NetGetDCName(argv[1], argv[2], &buffer);
if (status != 0) {
- printf("GetDcName failed with: %s\n", libnetapi_errstr(ctx, status));
+ printf("GetDcName failed with: %s\n", libnetapi_errstr(status));
} else {
printf("%s\n", (char *)buffer);
}
diff --git a/source/lib/netapi/examples/netdomjoin-gui/netdomjoin-gui.c b/source/lib/netapi/examples/netdomjoin-gui/netdomjoin-gui.c
index 4a3588e..9dc2a18 100644
--- a/source/lib/netapi/examples/netdomjoin-gui/netdomjoin-gui.c
+++ b/source/lib/netapi/examples/netdomjoin-gui/netdomjoin-gui.c
@@ -147,13 +147,13 @@ static void callback_apply_description_change(GtkWidget *widget,
status = NetServerSetInfo(NULL, 1005, (uint8_t *)&info1005, &parm_err);
if (status) {
debug("NetServerSetInfo failed with: %s\n",
- libnetapi_errstr(state->ctx, status));
+ libnetapi_errstr(status));
dialog = gtk_message_dialog_new(GTK_WINDOW(state->window_main),
GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_ERROR,
GTK_BUTTONS_OK,
"Failed to change computer description: %s.",
- libnetapi_errstr(state->ctx, status));
+ libnetapi_errstr(status));
g_signal_connect_swapped(dialog, "response",
G_CALLBACK(gtk_widget_destroy),
dialog);
@@ -439,7 +439,7 @@ static void callback_do_join(GtkWidget *widget,
state->password,
unjoin_flags);
if (status != 0) {
- err_str = libnetapi_errstr(state->ctx, status);
+ err_str = libnetapi_errstr(status);
g_print("callback_do_join: failed to unjoin (%s)\n",
err_str);
@@ -463,7 +463,7 @@ static void callback_do_join(GtkWidget *widget,
state->password,
join_flags);
if (status != 0) {
- err_str = libnetapi_errstr(state->ctx, status);
+ err_str = libnetapi_errstr(status);
g_print("callback_do_join: failed to join (%s)\n", err_str);
dialog = gtk_message_dialog_new(GTK_WINDOW(state->window_parent),
diff --git a/source/lib/netapi/examples/netdomjoin/netdomjoin.c b/source/lib/netapi/examples/netdomjoin/netdomjoin.c
index a0ac0b1..29f66a1 100644
--- a/source/lib/netapi/examples/netdomjoin/netdomjoin.c
+++ b/source/lib/netapi/examples/netdomjoin/netdomjoin.c
@@ -105,9 +105,9 @@ int main(int argc, char **argv)
join_flags);
if (status != 0) {
const char *errstr = NULL;
- errstr = libnetapi_get_error_string(ctx);
+ errstr = libnetapi_get_error_string(ctx, status);
if (!errstr) {
- errstr = libnetapi_errstr(ctx, status);
+ errstr = libnetapi_errstr(status);
}
printf("Join failed with: %s\n", errstr);
} else {
diff --git a/source/utils/net_dom.c b/source/utils/net_dom.c
index 3a8338e..30993ae 100644
--- a/source/utils/net_dom.c
+++ b/source/utils/net_dom.c
@@ -101,7 +101,7 @@ static int net_dom_unjoin(int argc, const char **argv)
status = NetUnjoinDomain(server_name, account, password, unjoin_flags);
if (status != 0) {
printf("Failed to unjoin domain: %s\n",
- libnetapi_errstr(ctx, status));
+ libnetapi_errstr(status));
goto done;
}
@@ -215,7 +215,7 @@ static int net_dom_join(int argc, const char **argv)
Account, password, join_flags);
if (status != 0) {
printf("Failed to join domain: %s\n",
- libnetapi_errstr(ctx, status));
+ libnetapi_errstr(status));
goto done;
}
--
Samba Shared Repository
More information about the samba-cvs
mailing list