Ok, I was able to make “Send CTRL+ALT+CANC” work in remmina with following patch.
Previously it did segfault.
I’ll now have to work on a more general purpose solution.
diff --git a/src/remmina_public.c b/src/remmina_public.c
index cdb40a7ae..af793e42d 100644
--- a/src/remmina_public.c
+++ b/src/remmina_public.c
@@ -60,6 +60,7 @@
#endif
#include "remmina_public.h"
#include "remmina/remmina_trace_calls.h"
+#include "remmina_log.h"
GtkWidget*
remmina_public_create_combo_entry(const gchar *text, const gchar *def, gboolean descending)
@@ -533,9 +534,21 @@ guint16 remmina_public_get_keycode_for_keyval(GdkKeymap *keymap, guint keyval)
guint16 keycode = 0;
if (gdk_keymap_get_entries_for_keyval(keymap, keyval, &keys, &length)) {
- keycode = keys[0].keycode;
- g_free(keys);
+ if(length > 0) {
+ keycode = keys[0].keycode;
+ g_free(keys);
+ }
+ }
+
+ if (keycode == 0) {
+ REMMINA_WARNING("Unable to find keycode for %u in %p, trying default", keyval, keymap);
+ if (keyval == 65507)
+ keycode = 37;
+ else if (keyval == 65513)
+ keycode = 64;
+ REMMINA_DEBUG("Fallback keymap %u -> %u", keyval, keycode);
}
+
return keycode;
}