From 88dc2e93bdc49ca40352078e94c68cc20a23a108 Mon Sep 17 00:00:00 2001 From: Ilia Maslakov Date: Thu, 14 Oct 2010 16:17:14 +0400 Subject: [PATCH] replace print_vfs_message to printf Signed-off-by: Ilia Maslakov --- lib/vfs/mc-vfs/fish.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/lib/vfs/mc-vfs/fish.c b/lib/vfs/mc-vfs/fish.c index 8fc6b49e1..ff120a48d 100644 --- a/lib/vfs/mc-vfs/fish.c +++ b/lib/vfs/mc-vfs/fish.c @@ -404,19 +404,18 @@ fish_open_archive_talk (struct vfs_class *me, struct vfs_s_super *super) { char answer[2048]; - print_vfs_message (_("fish: Waiting for initial line...")); + printf ("\n%s\n", _("fish: Waiting for initial line...")); if (!vfs_s_get_line (me, SUP.sockr, answer, sizeof (answer), ':')) return FALSE; - print_vfs_message ("%s", answer); if (strstr (answer, "assword")) { /* Currently, this does not work. ssh reads passwords from /dev/tty, not from stdin :-(. */ - message (D_ERROR, MSG_ERROR, - _("Sorry, we cannot do password authenticated connections for now.")); + printf ("\n%s\n", _("Sorry, we cannot do password authenticated connections for now.")); + return FALSE; #if 0 if (!SUP.password) @@ -429,7 +428,7 @@ fish_open_archive_talk (struct vfs_class *me, struct vfs_s_super *super) return FALSE; SUP.password = op; } - print_vfs_message (_("fish: Sending password...")); + printf ("\n%s\n", _("fish: Sending password...")); { size_t str_len; str_len = strlen (SUP.password); @@ -447,6 +446,7 @@ fish_open_archive_talk (struct vfs_class *me, struct vfs_s_super *super) static int fish_open_archive_int (struct vfs_class *me, struct vfs_s_super *super) { + gboolean ftalk; /* hide panels */ pre_exec (); @@ -454,10 +454,13 @@ fish_open_archive_int (struct vfs_class *me, struct vfs_s_super *super) fish_open_archive_pipeopen (super); /* Start talk with ssh-server (password prompt, etc ) */ - if (!fish_open_archive_talk (me, super)) - { + ftalk = fish_open_archive_talk (me, super); + + /* show panels */ + post_exec (); + + if (!ftalk) ERRNOR (E_PROTO, -1); - } print_vfs_message (_("fish: Sending initial line...")); /* @@ -465,9 +468,6 @@ fish_open_archive_int (struct vfs_class *me, struct vfs_s_super *super) * we'll talk directly to the shell. */ - /* show panels */ - post_exec (); - if (fish_command (me, super, WAIT_REPLY, "#FISH\necho; start_fish_server 2>&1; echo '### 200'\n") != COMPLETE) -- 2.11.4.GIT