diff --git a/0003_honour_soft_links_git_ee00da15.patch b/0003_honour_soft_links_git_ee00da15.patch new file mode 100644 index 0000000..b2ca779 --- /dev/null +++ b/0003_honour_soft_links_git_ee00da15.patch @@ -0,0 +1,127 @@ +diff --git a/src/remmina_ftp_client.c b/src/remmina_ftp_client.c +index 4466b356f4af4aa3ead29bf8b488f11bf936a061..82bff4e7ff0783b6fa2b437151dfc770f9370746 100644 +--- a/src/remmina_ftp_client.c ++++ b/src/remmina_ftp_client.c +@@ -202,6 +202,9 @@ static void remmina_ftp_client_cell_data_filetype_pixbuf(GtkTreeViewColumn *col, + case REMMINA_FTP_FILE_TYPE_DIR: + g_object_set(renderer, "icon-name", "folder", NULL); + break; ++ case REMMINA_FTP_FILE_TYPE_LINK: ++ g_object_set(renderer, "icon-name", "emblem-symbolic-link", NULL); ++ break; + default: + g_object_set(renderer, "icon-name", "text-x-generic", NULL); + break; +@@ -695,6 +698,9 @@ static gboolean remmina_ftp_client_file_list_on_button_press(GtkWidget *widget, + case REMMINA_FTP_FILE_TYPE_DIR: + remmina_ftp_client_open_dir(client, name); + break; ++ case REMMINA_FTP_FILE_TYPE_LINK: ++ remmina_ftp_client_open_dir(client, name); ++ break; + case REMMINA_FTP_FILE_TYPE_FILE: + default: + localdir = remmina_ftp_client_get_download_dir(client); +diff --git a/src/remmina_ftp_client.h b/src/remmina_ftp_client.h +index 5c1b688d141b0d4c31c7cd553a81ee3db5de80f0..9aa630b8f5641e7402687359e2b1d2177c88ca70 100644 +--- a/src/remmina_ftp_client.h ++++ b/src/remmina_ftp_client.h +@@ -66,7 +66,10 @@ GType remmina_ftp_client_get_type(void) + G_GNUC_CONST; + + enum { +- REMMINA_FTP_FILE_TYPE_DIR, REMMINA_FTP_FILE_TYPE_FILE, REMMINA_FTP_FILE_N_TYPES, ++ REMMINA_FTP_FILE_TYPE_DIR, ++ REMMINA_FTP_FILE_TYPE_FILE, ++ REMMINA_FTP_FILE_TYPE_LINK, ++ REMMINA_FTP_FILE_N_TYPES, + }; + + enum { +diff --git a/src/remmina_sftp_client.c b/src/remmina_sftp_client.c +index a16e72c0ad085b1fd25fff1dd1133cbe27e067a2..4aac1b025949e23cf4f54dd7e09b783caa2360d9 100644 +--- a/src/remmina_sftp_client.c ++++ b/src/remmina_sftp_client.c +@@ -48,6 +48,7 @@ + #include + #endif + #include "remmina_public.h" ++#include "remmina_log.h" + #include "remmina_pref.h" + #include "remmina_ssh.h" + #include "remmina_sftp_client.h" +@@ -73,10 +74,12 @@ remmina_sftp_client_class_init(RemminaSFTPClientClass *klass) + if (a->type == 0) \ + { \ + type = ((a->permissions & 040000) ? REMMINA_FTP_FILE_TYPE_DIR : REMMINA_FTP_FILE_TYPE_FILE); \ ++ type = ((a->permissions & 0120000) ? REMMINA_FTP_FILE_TYPE_LINK : REMMINA_FTP_FILE_TYPE_FILE); \ + } \ + else \ + { \ + type = (a->type == SSH_FILEXFER_TYPE_DIRECTORY ? REMMINA_FTP_FILE_TYPE_DIR : REMMINA_FTP_FILE_TYPE_FILE); \ ++ if (a->type == SSH_FILEXFER_TYPE_SYMLINK ) type = REMMINA_FTP_FILE_TYPE_LINK; \ + } + + /* ------------------------ The Task Thread routines ----------------------------- */ +@@ -274,6 +277,16 @@ remmina_sftp_client_thread_recursive_dir(RemminaSFTPClient *client, RemminaSFTP + else + dir_path = g_strdup(rootdir_path); + tmp = remmina_ssh_unconvert(REMMINA_SSH(sftp), dir_path); ++ ++ REMMINA_DEBUG ("%s HELLO", __func__); ++#if 0 ++ gchar *tlink = sftp_readlink (sftp->sftp_sess, tmp); ++ if (tlink) { ++ REMMINA_DEBUG ("%s is a link to %s", tmp, tlink); ++ tmp = g_strdup (tlink); ++ } ++ g_free(tlink); ++#endif + sftpdir = sftp_opendir(sftp->sftp_sess, tmp); + g_free(tmp); + +@@ -689,11 +702,10 @@ remmina_sftp_client_sftp_session_opendir(RemminaSFTPClient *client, const gchar + { + TRACE_CALL(__func__); + sftp_dir sftpdir; +- GtkWidget *dialog; + + sftpdir = sftp_opendir(client->sftp->sftp_sess, (gchar *)dir); + if (!sftpdir) { +- dialog = gtk_message_dialog_new(GTK_WINDOW(gtk_widget_get_toplevel(GTK_WIDGET(client))), ++ GtkWidget *dialog = gtk_message_dialog_new(GTK_WINDOW(gtk_widget_get_toplevel(GTK_WIDGET(client))), + GTK_DIALOG_MODAL, GTK_MESSAGE_ERROR, GTK_BUTTONS_OK, + _("Could not open the folder ā€œ%sā€. %s"), dir, + ssh_get_error(REMMINA_SSH(client->sftp)->session)); +@@ -708,10 +720,9 @@ static gboolean + remmina_sftp_client_sftp_session_closedir(RemminaSFTPClient *client, sftp_dir sftpdir) + { + TRACE_CALL(__func__); +- GtkWidget *dialog; + + if (!sftp_dir_eof(sftpdir)) { +- dialog = gtk_message_dialog_new(GTK_WINDOW(gtk_widget_get_toplevel(GTK_WIDGET(client))), ++ GtkWidget *dialog = gtk_message_dialog_new(GTK_WINDOW(gtk_widget_get_toplevel(GTK_WIDGET(client))), + GTK_DIALOG_MODAL, GTK_MESSAGE_ERROR, GTK_BUTTONS_OK, + _("Could not read from the folder. %s"), ssh_get_error(REMMINA_SSH(client->sftp)->session)); + gtk_dialog_run(GTK_DIALOG(dialog)); +@@ -750,6 +761,19 @@ remmina_sftp_client_on_opendir(RemminaSFTPClient *client, gchar *dir, gpointer d + } + } + ++ gchar *tlink = sftp_readlink (client->sftp->sftp_sess, newdir); ++ if (tlink) { ++ REMMINA_DEBUG ("%s is a link to %s", newdir, tlink); ++ newdir = g_strdup (tlink); ++ if (sftp_opendir (client->sftp->sftp_sess, newdir)) { ++ REMMINA_DEBUG ("%s is a link to a folder", tlink); ++ } else { ++ REMMINA_DEBUG ("%s is a link to a file", tlink); ++ return; ++ } ++ } ++ g_free(tlink); ++ + tmp = remmina_ssh_unconvert(REMMINA_SSH(client->sftp), newdir); + newdir_conv = sftp_canonicalize_path(client->sftp->sftp_sess, tmp); + g_free(tmp); diff --git a/0004_freerdp_offscreen_support_level_type_git_f58d22d6.patch b/0004_freerdp_offscreen_support_level_type_git_f58d22d6.patch new file mode 100644 index 0000000..821f02a --- /dev/null +++ b/0004_freerdp_offscreen_support_level_type_git_f58d22d6.patch @@ -0,0 +1,13 @@ +diff --git a/plugins/rdp/rdp_plugin.c b/plugins/rdp/rdp_plugin.c +index ea77799224e844ddf19c315e077d106822f97785..3df43f1a2a77f8f4e39bb77879268ff16f07aeef 100644 +--- a/plugins/rdp/rdp_plugin.c ++++ b/plugins/rdp/rdp_plugin.c +@@ -663,7 +663,7 @@ static BOOL remmina_rdp_pre_connect(freerdp *instance) + freerdp_settings_set_uint32(settings, FreeRDP_OsMajorType, OSMAJORTYPE_UNIX); + freerdp_settings_set_uint32(settings, FreeRDP_OsMinorType, OSMINORTYPE_UNSPECIFIED); + freerdp_settings_set_bool(settings, FreeRDP_BitmapCacheEnabled, TRUE); +- freerdp_settings_set_bool(settings, FreeRDP_OffscreenSupportLevel, TRUE); ++ freerdp_settings_set_uint32(settings, FreeRDP_OffscreenSupportLevel, 1); + + PubSub_SubscribeChannelConnected(instance->context->pubSub, + (pChannelConnectedEventHandler)remmina_rdp_OnChannelConnectedEventHandler); diff --git a/remmina.spec b/remmina.spec index 6acd577..adbcc03 100644 --- a/remmina.spec +++ b/remmina.spec @@ -2,7 +2,7 @@ Name: remmina Version: 1.4.24 -Release: 3%{?dist} +Release: 4%{?dist} Summary: Remote Desktop Client License: GPLv2+ and MIT URL: https://remmina.org @@ -23,6 +23,8 @@ Source1: pluginBuild-CMakeLists.txt # Patches. Patch0: 0001_fix_rare_crash_git_2609548e_and_9ed4c438.patch Patch1: 0002_drop_gnome_mediakeys_plugin_git_c901beef.patch +Patch2: 0003_honour_soft_links_git_ee00da15.patch +Patch3: 0004_freerdp_offscreen_support_level_type_git_f58d22d6.patch %if 0%{?fedora} || 0%{?rhel} >= 8 BuildRequires: cmake @@ -328,6 +330,10 @@ fi %{_mandir}/man1/remmina-gnome.1.* %changelog +* Wed Mar 09 2022 Phil Wyett - 1.4.24-4 +- Add patch: 0003_honour_soft_links_git_ee00da15.patch +- Add patch: 0004_freerdp_offscreen_support_level_type_git_f58d22d6.patch + * Sun Feb 27 2022 Phil Wyett - 1.4.24-3 - Add patch: 0001_fix_rare_crash_git_2609548e_and_9ed4c438.patch. - Add patch: 0002_drop_gnome_mediakeys_plugin_git_c901beef.patch.