Mercurial > gftp.yaz
diff src/uicommon/gftpui.c @ 380:05ee37a5558b
2003-1-28 Brian Masney <masneyb@gftp.org>
* src/gtk/bookmarks.c src/gtk/dnd.c src/gtk/gftp-gtk.c
src/gtk/gftp-gtk.h src/gtk/gtkui.c src/gtk/menu-items.c
src/gtk/transfer.c - renamed disconnect() to gftpui_disconnect()
* src/gtk/gtkui.c src/text/textui.c src/uicommon/gftpui.c - improved
prompting for the username/password
* src/gtk/gtkui.c src/text/textui.c src/uicommon/gftpui.c - call
gftpui_disconnect() after a command is run and if we are no longer
connected to the remote host
* src/text/gftp-text.c - parse the command line arguments for the host
to connect to
* src/text/textui.c (gftpui_refresh) - clear the cache.
(gftpui_ask_transfer) - check for carriage return or empty string
* src/uicommon/gftp.h - define gftpui_common_cmd_m{get,put}_file()
* lib/sshv2.c - removed temporary "fix"
author | masneyb |
---|---|
date | Wed, 28 Jan 2004 23:46:28 +0000 |
parents | 14da115b149b |
children | 2f5ce7fb5aad |
line wrap: on
line diff
--- a/src/uicommon/gftpui.c Wed Jan 28 10:52:53 2004 +0000 +++ b/src/uicommon/gftpui.c Wed Jan 28 23:46:28 2004 +0000 @@ -604,7 +604,6 @@ { gftpui_callback_data * cdata; intptr_t retries; - char *tempstr; if (GFTP_IS_CONNECTED (request)) { @@ -627,25 +626,12 @@ if (request->need_userpass) { if (request->username == NULL || *request->username == '\0') - { - if ((tempstr = gftpui_prompt_username (uidata, request)) != NULL) - { - gftp_set_username (request, tempstr); - gftp_set_password (request, NULL); - g_free (tempstr); - } - } + gftpui_prompt_username (uidata, request); if (request->username != NULL && strcmp (request->username, "anonymous") != 0 && (request->password == NULL || *request->password == '\0')) - { - if ((tempstr = gftpui_prompt_password (uidata, request)) != NULL) - { - gftp_set_password (request, tempstr); - g_free (tempstr); - } - } + gftpui_prompt_password (uidata, request); } gftp_lookup_request_option (request, "retries", &retries); @@ -1065,6 +1051,9 @@ { ret = gftpui_common_commands[i].func (uidata, request, other_uidata, other_request, pos); + + if (!GFTP_IS_CONNECTED (request)) + gftpui_disconnect (uidata); } else {