After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 697039 - users: taking photo doesn't work
users: taking photo doesn't work
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: User Accounts
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Ondrej Holy
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-04-01 12:29 UTC by Matthias Clasen
Modified: 2014-10-15 16:32 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
libcheese: Fix private structure access (2.21 KB, patch)
2014-10-14 18:22 UTC, Bastien Nocera
committed Details | Review
libcheese: Work-around crasher bug (28.79 KB, patch)
2014-10-15 10:37 UTC, Bastien Nocera
reviewed Details | Review
rename UmCropArea to CcCropArea (65.30 KB, patch)
2014-10-15 12:48 UTC, David King
committed Details | Review

Description Matthias Clasen 2013-04-01 12:29:23 UTC
when trying to take a photo, I do get the live preview ok, but when I click 'take photo', I am left with a screen-size, all-gray window that doesn't go away.
Comment 1 Ondrej Holy 2013-06-13 12:33:20 UTC
Are you still facing up the bug? Taking photo works for me great on master.
Comment 2 Yosef Or Boczko 2014-05-06 14:25:25 UTC
When I see click on 'Take a Photo' I see flash and than crash. here bt:

(gnome-control-center:23068): GLib-GObject-CRITICAL **: g_object_unref: assertion 'G_IS_OBJECT (object)' failed

(gnome-control-center:23068): GLib-GObject-WARNING **: invalid uninstantiatable type '(null)' in cast to 'GtkWidget'

(gnome-control-center:23068): Gtk-CRITICAL **: gtk_widget_queue_draw: assertion 'GTK_IS_WIDGET (widget)' failed

(gnome-control-center:23068): Gtk-CRITICAL **: gtk_widget_get_visible: assertion 'GTK_IS_WIDGET (widget)' failed

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff211aaa4 in gtk_widget_verify_invariants (widget=0x2c0c900) at gtkwidget.c:9494
warning: Source file is more recent than executable.
9494	  if (widget->priv->verifying_invariants_count > 0)
(gdb) bt
  • #0 gtk_widget_verify_invariants
    at gtkwidget.c line 9494
  • #1 gtk_frame_forall
    at gtkframe.c line 369
  • #2 gtk_grid_forall
    at gtkgrid.c line 549
  • #3 gtk_container_map
    at gtkcontainer.c line 3447
  • #4 g_closure_invoke
    at gclosure.c line 768
  • #5 signal_emit_unlocked_R
    at gsignal.c line 3481
  • #6 g_signal_emit_valist
    at gsignal.c line 3307
  • #7 g_signal_emit
    at gsignal.c line 3363
  • #8 gtk_widget_map
    at gtkwidget.c line 4593
  • #9 gtk_widget_set_child_visible
    at gtkwidget.c line 9993
  • #10 gtk_notebook_real_switch_page
    at gtknotebook.c line 6790
  • #11 g_closure_invoke
    at gclosure.c line 768
  • #12 signal_emit_unlocked_R
    at gsignal.c line 3589
  • #13 g_signal_emit_valist
    at gsignal.c line 3307
  • #14 g_signal_emit
    at gsignal.c line 3363
  • #15 gtk_notebook_switch_page
    at gtknotebook.c line 6832
  • #16 gtk_notebook_set_current_page
    at gtknotebook.c line 7401
  • #17 cheese_widget_photo_taken_cb
    at libcheese/cheese-avatar-widget.c line 96
  • #18 g_cclosure_marshal_VOID__OBJECTv
    at gmarshal.c line 1312
  • #19 _g_closure_invoke_va
    at gclosure.c line 831
  • #20 g_signal_emit_valist
    at gsignal.c line 3215
  • #21 g_signal_emit
    at gsignal.c line 3363
  • #22 cheese_camera_photo_data
    at libcheese/cheese-camera.c line 176
  • #23 cheese_camera_bus_message_cb
    at libcheese/cheese-camera.c line 262
  • #24 g_cclosure_marshal_VOID__BOXEDv
    at gmarshal.c line 1160
  • #25 _g_closure_invoke_va
    at gclosure.c line 831
  • #26 g_signal_emit_valist
    at gsignal.c line 3215
  • #27 g_signal_emit
    at gsignal.c line 3363
  • #28 gst_bus_async_signal_func
    from /usr/lib/libgstreamer-1.0.so.0
  • #29 ??
    from /usr/lib/libgstreamer-1.0.so.0
  • #30 g_main_dispatch
    at gmain.c line 3064
  • #31 g_main_context_dispatch
    at gmain.c line 3663
  • #32 g_main_context_iterate
    at gmain.c line 3734
  • #33 g_main_context_iteration
    at gmain.c line 3795
  • #34 g_application_run
    at gapplication.c line 2115
  • #35 main
    at main.c line 49

Comment 3 Ondrej Holy 2014-05-08 14:14:20 UTC
Thanks for your bug report. I can reproduce it either. Looks like problem with cheese, however I have recently updated my desktop to Gnome 3.12. I think it was working with Gnome 3.10 properly, unfortunately my virtualized Fedora 20 with Gnome 3.10 doesn't see the webcam. Have you upgraded your Gnome either?
Comment 4 Ondrej Holy 2014-06-24 11:39:34 UTC
Looks like problem in cheese, changing component...

It fails for me with different backtrace (updated Fedora 21 with Gnome 3.12 from copr):

  • #0 g_type_check_instance_is_fundamentally_a
    at gtype.c line 3983
  • #1 g_object_unref
    at gobject.c line 3020
  • #2 um_crop_area_set_picture
    at libcheese/um-crop-area.c line 968
  • #3 cheese_widget_photo_taken_cb
    at libcheese/cheese-avatar-widget.c line 95
  • #4 g_cclosure_marshal_VOID__OBJECTv
    at gmarshal.c line 1312
  • #5 _g_closure_invoke_va
    at gclosure.c line 831
  • #6 g_signal_emit_valist
    at gsignal.c line 3219
  • #7 g_signal_emit
    at gsignal.c line 3367
  • #8 cheese_camera_photo_data
    at libcheese/cheese-camera.c line 176
  • #9 cheese_camera_bus_message_cb
    at libcheese/cheese-camera.c line 262
  • #10 g_cclosure_marshal_VOID__BOXEDv
    at gmarshal.c line 1160
  • #11 _g_closure_invoke_va
    at gclosure.c line 831
  • #12 g_signal_emit_valist
    at gsignal.c line 3219
  • #13 g_signal_emit
    at gsignal.c line 3367
  • #14 gst_bus_async_signal_func
    at gstbus.c line 1122
  • #15 gst_bus_source_dispatch
    at gstbus.c line 769
  • #16 g_main_dispatch
    at gmain.c line 3064
  • #17 g_main_context_dispatch
    at gmain.c line 3663
  • #18 g_main_context_iterate
    at gmain.c line 3734
  • #19 g_main_context_iteration
    at gmain.c line 3795
  • #20 g_application_run
    at gapplication.c line 2115
  • #21 main
    at main.c line 49

Comment 5 Ondrej Holy 2014-10-14 15:25:09 UTC
This commit triggers the issue:
https://git.gnome.org/browse/cheese/commit/?id=3b3105828787f988c0865e4ef4117d0742f6b527
Comment 6 Bastien Nocera 2014-10-14 18:13:00 UTC
(In reply to comment #5)
> This commit triggers the issue:
> https://git.gnome.org/browse/cheese/commit/?id=3b3105828787f988c0865e4ef4117d0742f6b527

Yep, the cheese-camera.c chunk is half-ported.
Comment 7 Bastien Nocera 2014-10-14 18:22:09 UTC
Created attachment 288542 [details] [review]
libcheese: Fix private structure access

We were still using CHEESE_CAMERA_GET_PRIVATE() instead of the
G_DEFINE_TYPE_WITH_PRIVATE() provided macro.

This a regression caused by 3b3105828787f988c0865e4ef4117d0742f6b527
Comment 8 David King 2014-10-14 18:41:29 UTC
Review of attachment 288542 [details] [review]:

Already pushed an identical patch as bf5c9922eb1db09467795047b310e554ba990a38 (and a couple of other cleanups). They do not fix the bug, unfortunately.
Comment 9 Bastien Nocera 2014-10-15 10:37:39 UTC
The bug is in the um-crop-area changes.
Comment 10 Bastien Nocera 2014-10-15 10:37:48 UTC
Created attachment 288573 [details] [review]
libcheese: Work-around crasher bug
Comment 11 Bastien Nocera 2014-10-15 10:38:31 UTC
This patch fixes the crash. Now if somebody wants to play spot the bug...
Comment 12 David King 2014-10-15 12:30:38 UTC
Review of attachment 288573 [details] [review]:

Patch seems fine-ish, although it would be good to fix this properly, and I think that I found the underlying cause. The bug itself seems to be that libcheese-gtk exports a um_crop_area_get_type() function, and g-c-c also has the same function for its internal copy. This gets a bit messy, especially when the two objects are different (which was made obvious by the G_DEFINE_TYPE_WITH_PRIVATE rework in Cheese). Putting the Cheese version of UmCropArea into g-c-c does not fix the problem, but renaming one of the two versions does. As the get_type() function is publically visible in libcheese-gtk, changing the name there would be an ABI break, so I will postpone that to next cycle. The next best thing is to rename the UmCropArea in the control center to CcCropArea.
Comment 13 David King 2014-10-15 12:48:24 UTC
Created attachment 288578 [details] [review]
rename UmCropArea to CcCropArea
Comment 14 Ondrej Holy 2014-10-15 12:53:28 UTC
It seems to me for the first look, UmCropArea in g-c-c is just copy of UmCropArea from cheese. It would be better to synchronize those files or remove it if it is possible. Will have to look at...
Comment 15 Ondrej Holy 2014-10-15 12:58:38 UTC
Grrr, we need this to crop pictures from file (not from camera). I really don't like this "code sharing".
Comment 16 David King 2014-10-15 14:03:47 UTC
UmCropArea in Cheese is a copy of the control center code (in 2010, and synced up occasionally after that). Copying the Cheese code back to the control center does not fix the bug. It might be possible to not export the type in libcheese-gtk, but I think that would still confuse GType if the type names were identical. Another option would be to only enable the local copy if Cheese support is disabled, but then Cheese would need to export the complete API rather than just the _get_type() function. Bastien already acked the patch on IRC, but I am waiting on git.gnome.org to be able to push it.
Comment 17 David King 2014-10-15 14:10:20 UTC
Review of attachment 288578 [details] [review]:

Pushed to master and gnome-3-12.