summaryrefslogtreecommitdiff
path: root/source4/gtk/common
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2005-03-21 21:22:07 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:11:08 -0500
commit05bc2d7b2c11a3583a6d1221cfbd618eb6730518 (patch)
treef0c2966e0a67c381ae1a94cd5c33c59ea8d33f14 /source4/gtk/common
parent34cde065139fdc76f6aa529426cfc1f68a394d54 (diff)
downloadsamba-05bc2d7b2c11a3583a6d1221cfbd618eb6730518.tar.gz
samba-05bc2d7b2c11a3583a6d1221cfbd618eb6730518.tar.bz2
samba-05bc2d7b2c11a3583a6d1221cfbd618eb6730518.zip
r5928: Use cli_credentials in:
- gtk+ (returned by GtkHostBindingDialog as well now) - torture/ - librpc/ - lib/com/dcom/ (This used to be commit ccefd782335e01e8e6ecb2bcd28a4f999c53b1a6)
Diffstat (limited to 'source4/gtk/common')
-rw-r--r--source4/gtk/common/gtk-smb.c19
-rw-r--r--source4/gtk/common/gtk-smb.h4
2 files changed, 8 insertions, 15 deletions
diff --git a/source4/gtk/common/gtk-smb.c b/source4/gtk/common/gtk-smb.c
index f42516c854..06bca9bf86 100644
--- a/source4/gtk/common/gtk-smb.c
+++ b/source4/gtk/common/gtk-smb.c
@@ -297,19 +297,14 @@ GtkWidget *gtk_rpc_binding_dialog_new (BOOL nocredentials, struct sam_pipe *sam_
return GTK_WIDGET(d);
}
-const char *gtk_rpc_binding_dialog_get_username(GtkRpcBindingDialog *d)
+struct cli_credentials *gtk_rpc_binding_dialog_get_credentials(GtkRpcBindingDialog *d)
{
- return gtk_entry_get_text(GTK_ENTRY(d->entry_username));
-}
-
-const char *gtk_rpc_binding_dialog_get_userdomain(GtkRpcBindingDialog *d)
-{
- return gtk_entry_get_text(GTK_ENTRY(d->entry_userdomain));
-}
-
-const char *gtk_rpc_binding_dialog_get_password(GtkRpcBindingDialog *d)
-{
- return gtk_entry_get_text(GTK_ENTRY(d->entry_password));
+ struct cli_credentials *ret = talloc(d->mem_ctx, struct cli_credentials);
+ cli_credentials_set_username(ret, gtk_entry_get_text(GTK_ENTRY(d->entry_username)), CRED_SPECIFIED);
+ cli_credentials_set_password(ret, gtk_entry_get_text(GTK_ENTRY(d->entry_password)), CRED_SPECIFIED);
+ cli_credentials_set_domain(ret, gtk_entry_get_text(GTK_ENTRY(d->entry_userdomain)), CRED_SPECIFIED);
+
+ return ret;
}
const char *gtk_rpc_binding_dialog_get_host(GtkRpcBindingDialog *d)
diff --git a/source4/gtk/common/gtk-smb.h b/source4/gtk/common/gtk-smb.h
index e85eb5be85..e78e8541f8 100644
--- a/source4/gtk/common/gtk-smb.h
+++ b/source4/gtk/common/gtk-smb.h
@@ -71,9 +71,7 @@ const char *gtk_select_host_dialog_get_host (GtkSelectHostDialog *d);
GType gtk_select_host_dialog_get_type (void);
void gtk_show_werror(GtkWidget *win, WERROR err);
const char *gtk_rpc_binding_dialog_get_binding_string(GtkRpcBindingDialog *d, TALLOC_CTX *mem_ctx);
-const char *gtk_rpc_binding_dialog_get_username(GtkRpcBindingDialog *d);
-const char *gtk_rpc_binding_dialog_get_userdomain(GtkRpcBindingDialog *d);
-const char *gtk_rpc_binding_dialog_get_password(GtkRpcBindingDialog *d);
+struct cli_credentials *gtk_rpc_binding_dialog_get_credentials(GtkRpcBindingDialog *d);
const char *gtk_rpc_binding_dialog_get_host(GtkRpcBindingDialog *d);
GtkWidget *gtk_select_domain_dialog_new (struct dcerpc_pipe *sam_pipe);
GType gtk_select_domain_dialog_get_type (void);