Created attachment 2998 backtrace of the crash Forwarded from https://bugzilla.redhat.com/show_bug.cgi?id=597207 abrt 1.1.1 detected a crash. architecture: x86_64 Attached file: backtrace cmdline: /usr/libexec/xfce4/panel-plugins/xfce4-xkb-plugin socket_id 25165875 name xkb-plugin id 12632952080 display_name 'Keyboard Layouts' size 26 screen_position 2 comment: it doesn't crash If I choose keyboard model and set the "change layout option" component: xfce4-xkb-plugin crash_function: IA__gtk_tree_model_get_valist executable: /usr/libexec/xfce4/panel-plugins/xfce4-xkb-plugin global_uuid: 75c9a18eab4bac42cb5688101e6dfcef60037944 kernel: 2.6.33.4-95.fc13.x86_64 package: xfce4-xkb-plugin-0.5.3.3-3.fc13 rating: 4 reason: Process /usr/libexec/xfce4/panel-plugins/xfce4-xkb-plugin was killed by signal 11 (SIGSEGV) release: Fedora release 13 (Goddard) How to reproduce ----- 1. add Keyboard Layouts plugin to the panel 2. leave all combos on defaults (model: empty, c layout option: -, compose key: -) 3. CLick Add layout -> Czechia -> qwerty
Please fix this asap, lots of users are affected!
There are several times things like that: gtk_tree_model_get_iter_first (model, &iter); gtk_tree_model_get (model, &iter, NOM, &id, -1); (a gtk_tree_model_get_iter() call followed by gtk_tree_model_get()). AIUI, it's wrong: these get_iter funcs can fail to set the iter and return FALSE (http://library.gnome.org/devel/gtk/unstable/GtkTreeModel.html#gtk-tree-model-get-iter-first). Since the code snippet above doesn't check its return value, it can pass an unset iter to gtk_tree_model_get, which might crash just as we can see in the backtrace.
Created attachment 3119 Proposed patch Mmmh, no, I didn't look at the correct place, so it's probably simpler than that. In the code, there's no check on the validity on the iter set by gtk_combo_box_get_active_iter() for the keyboard model. So when you have an empty model, I guess the iter isn't valid. The attached patch might fix it for you (unfortunately, I can't check/reproduce, because I've always a keyboard model set, so it's never empty).
*** Bug 6720 has been marked as a duplicate of this bug. ***
Fixed in http://git.xfce.org/panel-plugins/xfce4-xkb-plugin/commit/?id=9b71c8e7e750f2b1fa1df038e54eff1fddf76262 Thanks for patch!