GNOME Bugzilla – Bug 363609
gnome-terminal crash if you create the exactly the same name profile
Last modified: 2007-11-27 02:31:12 UTC
Opensolaris build 51(vermillion), gnome 2.16 Steps: 1. Create a profile named "test" in gnome-terminal(Edit->Profiles) 2. Create another profile named "test" too 3. Select "Yes" when pop up dialog tell you there already have one named "test" Actual results: gnome-terminal crash: 1471: gnome-terminal ----------------- lwp# 1 / thread# 1 -------------------- d2768df5 waitid (0, b84, 8045c50, 3) d275c016 waitpid (b84, 8045d64, 0) + 70 d0301072 libgnomeui_segv_handle (b, 0, 8045e04) + ba d276747f __sighndlr (b, 0, 8045e04, d0300fb8) + f d275ccab call_user_handler (b, 0, 8045e04) + 2b8 d275ce52 sigacthandler (b, 0, 8045e04) + c2 --- called from signal handler with signal 11 (SIGSEGV) --- d023d3fa gconf_concat_dir_and_key (10101, 80893fc) + 2e 0806da5c terminal_profile_update (0) + 38 080679ba new_profile_response_callback (8781228, fffffffd, 8134960) + 182 d24cea37 g_cclosure_marshal_VOID__INT (84997f8, 0, 2, 804620c, 804616c, 0) + 5b d24ba41b g_closure_invoke (84997f8, 0, 2, 804620c, 804616c) + 107 d24ce076 signal_emit_unlocked_R (8186b88, 0, 8781228, 0, 804620c) + 746 d24cd388 g_signal_emit_valist (8781228, f5, 0, 8046478) + 8c4 d24cd51d g_signal_emit (8781228, f5, 0, fffffffd) + 25 cffc2a9f gtk_dialog_response (8781228, fffffffd) + 3b cffc243e action_widget_activated (88d8e68, 8781228) + 2a d24ce7f1 g_cclosure_marshal_VOID__VOID (8c458a8, 0, 1, 804661c, 804657c, 0) + 55 d24ba41b g_closure_invoke (8c458a8, 0, 1, 804661c, 804657c) + 107 d24ce076 signal_emit_unlocked_R (82c0fc0, 0, 88d8e68, 0, 804661c) + 746 d24cd388 g_signal_emit_valist (88d8e68, d9, 0, 8046888) + 8c4 d24cd51d g_signal_emit (88d8e68, d9, 0) + 25 cff80d44 gtk_button_clicked (88d8e68) + 38 cff81b74 gtk_real_button_released (88d8e68, 80bea00) + 38 d24ce7f1 g_cclosure_marshal_VOID__VOID (82680e8, 0, 1, 8046a5c, 80469bc, cff81b3c) + 55 d24ba6fc g_type_class_meta_marshal (82680e8, 0, 1, 8046a5c, 80469bc, 1a4) + 40 d24ba41b g_closure_invoke (82680e8, 0, 1, 8046a5c, 80469bc) + 107 d24cdd44 signal_emit_unlocked_R (82bf718, 0, 88d8e68, 0, 8046a5c) + 414 d24cd388 g_signal_emit_valist (88d8e68, d8, 0, 8046cc8) + 8c4 d24cd51d g_signal_emit (88d8e68, d8, 0) + 25 cff80cd8 gtk_button_released (88d8e68) + 38 cff819dc gtk_button_button_release (88d8e68, 8a18288, 80be020) + 24 d0031848 _gtk_marshal_BOOLEAN__BOXED (80ca5b8, 8046de0, 2, 8046e9c, 8046dfc, cff819b8) + 70 d24ba6fc g_type_class_meta_marshal (80ca5b8, 8046de0, 2, 8046e9c, 8046dfc, b4) + 40 d24ba41b g_closure_invoke (80ca5b8, 8046de0, 2, 8046e9c, 8046dfc) + 107 d24ce23a signal_emit_unlocked_R (80c7d98, 0, 88d8e68, 804701c, 8046e9c) + 90a d24cd126 g_signal_emit_valist (88d8e68, 1d, 0, 8047110) + 662 d24cd51d g_signal_emit (88d8e68, 1d, 0, 8a18288, 8047134) + 25 d013384b gtk_widget_event_internal (88d8e68, 8a18288) + 20f d01334dd gtk_widget_event (88d8e68, 8a18288) + 99 d0030498 gtk_propagate_event (88d8e68, 8a18288) + 98 d002f52d gtk_main_do_event (8a18288, 0) + 3b1 d266ea8e gdk_event_dispatch (80bca60, 0, 0) + 56 d25401f5 g_main_dispatch (80bcaa8) + 1d9 d25412e5 g_main_context_dispatch (80bcaa8) + 85 d2541702 g_main_context_iterate (80bcaa8, 1, 1, 80a9c88) + 3ce d2541d04 g_main_loop_run (8344490) + 1b8 d002ee5a gtk_main (8047534, 8047420, d27fb7c0, 8047378, 8086910, d0344118) + b2 08066dee main (1, 8047464, 804746c) + 58e 08060c6e _start (1, 804759c, 0, 80475ab, 80475cc, 8047600) + 7a ----------------- lwp# 2 / thread# 2 -------------------- d2768575 read (18, ce3bbf7c, 14) d2542dfe child_watch_helper_thread (0) + 2a d255b256 g_thread_create_proxy (83c7e18) + 11a d2767124 _thr_setup (d2472400) + 52 d2767380 _lwp_start (d2472400, 0, 0, 0, 0, 0)
I can reproduce this following Patrick's steps. This happens because terminal.c:new_profile_response_callback calls terminal_profile_create with the ‘visible’ profile name, but that function may change it to avoid a clash; but when it is done, new_profile_response_callback calls terminal_profile_new with the (escaped) visible name again, and that is not good. The call to terminal_profile_new should be done with the uniquified profilename that terminal_profile_create created, so _create should be changed to return that name. In any case, I propose we do not allow the user to create a profile with the same name as the visible name of an existing profile. What good can result from allowing that? We'll need to check that renaming a profile through the profile editor dialog does not result in a name clash.
Hello, I fount a variant of this bug, when the previous profile was renamed : Steps to reproduce the crash: 1. Create a first profile named test1 2. Go back to menu, edit test1 and rename it as "test2" 3. Create a second profile named "test1", then press ok. gnome-term should be crash. Additional Information: - I have noticed that once the first profile test1 is renamed, it's name isn't changed in gconf's /apps/gnome-terminal/profiles/test1/ (but "visible_name" is set to "test2"). - The new "test1" profile is properly created. - This bugs affects at leat 2.14.2 (debian/etch-rc1) and 2.16.1 (ubuntu/06.10)
*** Bug 343336 has been marked as a duplicate of this bug. ***
*** Bug 401920 has been marked as a duplicate of this bug. ***
*** Bug 366048 has been marked as a duplicate of this bug. ***
*** Bug 410598 has been marked as a duplicate of this bug. ***
https://bugs.launchpad.net/ubuntu/+source/gnome-terminal/+bug/103109 has a debug backtrace at http://librarian.launchpad.net/7154234/%3Cfdopen%3E
Thanks for taking the time to report this bug. This particular bug has already been reported into our bug tracking system, but we are happy to tell you that the problem has already been fixed. It should be solved in the next software version. You may want to check for a software upgrade. *** This bug has been marked as a duplicate of 499797 ***