mirror of https://github.com/MidnightCommander/mc
* src/boxes.c, vfs/ftpfs.[ch]: Add checkbox to allow passive FTP
over proxy to VFS dialog.
This commit is contained in:
parent
3be17f6657
commit
2bba061bf0
|
@ -1,3 +1,8 @@
|
|||
2005-05-29 Leonard den Ottolander <leonard * den ottolander nl>
|
||||
|
||||
* boxes.c: Added checkbox to VFS dialog to allow passive FTP
|
||||
over a proxy.
|
||||
|
||||
2005-05-29 Jindrich Novy <jnovy@redhat.com>
|
||||
|
||||
* main.c (midnight_callback): Fix blocking of panel cd-ing when
|
||||
|
|
15
src/boxes.c
15
src/boxes.c
|
@ -692,7 +692,7 @@ tree_box (const char *current_dir)
|
|||
#ifdef USE_VFS
|
||||
|
||||
#if defined(USE_NETCODE)
|
||||
#define VFSY 16
|
||||
#define VFSY 17
|
||||
#define VFS_WIDGETBASE 9
|
||||
#else
|
||||
#define VFSY 8
|
||||
|
@ -709,6 +709,7 @@ static char *ret_directory_timeout;
|
|||
static char *ret_ftp_proxy;
|
||||
static int ret_use_netrc;
|
||||
static int ret_ftpfs_use_passive_connections;
|
||||
static int ret_ftpfs_use_passive_connections_over_proxy;
|
||||
#endif
|
||||
|
||||
static QuickWidget confvfs_widgets [] = {
|
||||
|
@ -717,6 +718,8 @@ static QuickWidget confvfs_widgets [] = {
|
|||
{ quick_button, 12, VFSX, VFSY - 3, VFSY, N_("&OK"),
|
||||
0, B_ENTER, 0, 0, "button-ok" },
|
||||
#if defined(USE_NETCODE)
|
||||
{ quick_checkbox, 4, VFSX, 12, VFSY, N_("Use passive mode over pro&xy"), 0, 0,
|
||||
&ret_ftpfs_use_passive_connections_over_proxy, 0, "check-use-passive-mode-proxy" },
|
||||
{ quick_checkbox, 4, VFSX, 11, VFSY, N_("Use &passive mode"), 0, 0,
|
||||
&ret_ftpfs_use_passive_connections, 0, "check-use-passive-mode" },
|
||||
{ quick_checkbox, 4, VFSX, 10, VFSY, N_("&Use ~/.netrc"), 0, 0,
|
||||
|
@ -758,13 +761,14 @@ configure_vfs (void)
|
|||
|
||||
ret_use_netrc = use_netrc;
|
||||
ret_ftpfs_use_passive_connections = ftpfs_use_passive_connections;
|
||||
ret_ftpfs_use_passive_connections_over_proxy = ftpfs_use_passive_connections_over_proxy;
|
||||
g_snprintf(buffer3, sizeof (buffer3), "%i", ftpfs_directory_timeout);
|
||||
confvfs_widgets[7].text = buffer3;
|
||||
confvfs_widgets[9].text = ftpfs_anonymous_passwd;
|
||||
confvfs_widgets[4].text = ftpfs_proxy_host;
|
||||
confvfs_widgets[8].text = buffer3;
|
||||
confvfs_widgets[10].text = ftpfs_anonymous_passwd;
|
||||
confvfs_widgets[5].text = ftpfs_proxy_host;
|
||||
#endif
|
||||
g_snprintf (buffer2, sizeof (buffer2), "%i", vfs_timeout);
|
||||
confvfs_widgets [3 + VFS_WIDGETBASE].text = buffer2;
|
||||
confvfs_widgets [4 + VFS_WIDGETBASE].text = buffer2;
|
||||
|
||||
if (quick_dialog (&confvfs_dlg) != B_CANCEL) {
|
||||
vfs_timeout = atoi (ret_timeout);
|
||||
|
@ -779,6 +783,7 @@ configure_vfs (void)
|
|||
ftpfs_directory_timeout = atoi(ret_directory_timeout);
|
||||
use_netrc = ret_use_netrc;
|
||||
ftpfs_use_passive_connections = ret_ftpfs_use_passive_connections;
|
||||
ftpfs_use_passive_connections_over_proxy = ret_ftpfs_use_passive_connections_over_proxy;
|
||||
g_free (ret_directory_timeout);
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2005-05-29 Leonard den Ottolander <leonard * den ottolander nl>
|
||||
|
||||
* ftpfs.[ch]: Added variables and assignment to allow passive
|
||||
FTP over a proxy.
|
||||
|
||||
2005-05-24 Roland Illig <roland.illig@gmx.de>
|
||||
|
||||
* samba/param/loadparm.c: Fixed warnings reported by gcc-2.95.
|
||||
|
|
|
@ -108,6 +108,7 @@ int ftpfs_retry_seconds = 30;
|
|||
|
||||
/* Method to use to connect to ftp sites */
|
||||
int ftpfs_use_passive_connections = 1;
|
||||
int ftpfs_use_passive_connections_over_proxy = 0;
|
||||
|
||||
/* Method used to get directory listings:
|
||||
* 1: try 'LIST -la <path>', if it fails
|
||||
|
@ -703,8 +704,8 @@ ftpfs_open_archive_int (struct vfs_class *me, struct vfs_s_super *super)
|
|||
|
||||
/* We do not want to use the passive if we are using proxies */
|
||||
if (SUP.proxy)
|
||||
SUP.use_passive_connection = 0;
|
||||
|
||||
SUP.use_passive_connection = ftpfs_use_passive_connections_over_proxy;
|
||||
|
||||
retry_seconds = 0;
|
||||
do {
|
||||
SUP.failed_on_login = 0;
|
||||
|
|
|
@ -8,6 +8,7 @@ extern int ftpfs_always_use_proxy;
|
|||
|
||||
extern int ftpfs_retry_seconds;
|
||||
extern int ftpfs_use_passive_connections;
|
||||
extern int ftpfs_use_passive_connections_over_proxy;
|
||||
extern int ftpfs_use_unix_list_options;
|
||||
extern int ftpfs_first_cd_then_ls;
|
||||
|
||||
|
|
Loading…
Reference in New Issue