[vinagre] Make ssh_vinagre_connect() symbol visible in .so.
- From: Jonh Wendell <jwendell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vinagre] Make ssh_vinagre_connect() symbol visible in .so.
- Date: Wed, 14 Apr 2010 13:19:19 +0000 (UTC)
commit 6b1c01f15e5a698fc5f7e8f62e230adab94618bb
Author: Jonh Wendell <jwendell gnome org>
Date: Wed Apr 14 10:17:42 2010 -0300
Make ssh_vinagre_connect() symbol visible in .so.
This fixes a crash when using SSH tunnel in VNC plugin.
Closes Ubuntu #516847.
vinagre/vinagre-main.c | 4 ++++
vinagre/vinagre-ssh.c | 3 ++-
vinagre/vinagre-utils.c | 7 -------
3 files changed, 6 insertions(+), 8 deletions(-)
---
diff --git a/vinagre/vinagre-main.c b/vinagre/vinagre-main.c
index 4f6f3bf..b2d224b 100644
--- a/vinagre/vinagre-main.c
+++ b/vinagre/vinagre-main.c
@@ -40,6 +40,7 @@
#include "vinagre-plugin-info.h"
#include "vinagre-plugin-info-priv.h"
#include "vinagre-debug.h"
+#include "vinagre-ssh.h"
#ifdef HAVE_TELEPATHY
#include "vinagre-tubes-manager.h"
@@ -223,6 +224,9 @@ int main (int argc, char **argv) {
vinagre_tubes_manager = vinagre_tubes_manager_new (window);
#endif
+ /* fake call, just to ensure this symbol will be present at vinagre.so */
+ vinagre_ssh_connect (NULL, NULL, -1, NULL, NULL, NULL, NULL, NULL);
+
gtk_main ();
#ifdef HAVE_TELEPATHY
diff --git a/vinagre/vinagre-ssh.c b/vinagre/vinagre-ssh.c
index e26c63f..0d59ed9 100644
--- a/vinagre/vinagre-ssh.c
+++ b/vinagre/vinagre-ssh.c
@@ -664,7 +664,8 @@ vinagre_ssh_connect (GtkWindow *parent,
GInputStream *is;
GDataInputStream *error_stream;
- g_return_val_if_fail (hostname != NULL, FALSE);
+ if (!hostname)
+ return FALSE;
if (vendor == SSH_VENDOR_INVALID)
vendor = get_ssh_client_vendor ();
diff --git a/vinagre/vinagre-utils.c b/vinagre/vinagre-utils.c
index 03181f1..0b00045 100644
--- a/vinagre/vinagre-utils.c
+++ b/vinagre/vinagre-utils.c
@@ -607,13 +607,6 @@ vinagre_utils_ask_question (GtkWindow *parent,
return TRUE;
}
-#include "vinagre-ssh.h"
-static void
-shit (void)
-{
- vinagre_ssh_connect (NULL, NULL, -1, NULL, NULL, NULL, NULL, NULL);
-}
-
typedef struct {
GtkWidget *uname, *pw, *button;
} ControlOKButton;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]