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 731224 - Crash in can_remove if g_uri_parse_scheme fails
Crash in can_remove if g_uri_parse_scheme fails
Status: RESOLVED FIXED
Product: grilo
Classification: Other
Component: plugins
unspecified
Other Linux
: Normal major
: ---
Assigned To: grilo-maint
grilo-maint
Depends on:
Blocks:
 
 
Reported: 2014-06-04 15:54 UTC by Joanmarie Diggs (IRC: joanie)
Modified: 2014-06-04 18:24 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
lua-factory: Fix broken URLs for Euronews outside Europe (1.25 KB, patch)
2014-06-04 16:49 UTC, Bastien Nocera
committed Details | Review

Description Joanmarie Diggs (IRC: joanie) 2014-06-04 15:54:52 UTC
Totem is reliably segfaulting for me when I select the Euronews channel.

==============

  • #0 __strcmp_ssse3
    at ../sysdeps/x86_64/strcmp.S line 209
  • #1 g_str_equal
    at ghash.c line 1776
  • #2 can_remove
    at totem-grilo.c line 341
  • #3 add_media_to_model
    at totem-grilo.c line 647
  • #4 browse_cb
    at totem-grilo.c line 715
  • #5 queue_process
    at grl-source.c line 2077
  • #6 g_main_dispatch
    at gmain.c line 3064
  • #7 g_main_context_dispatch
    at gmain.c line 3663
  • #8 g_main_context_iterate
    at gmain.c line 3734
  • #9 g_main_context_iteration
    at gmain.c line 3795
  • #10 g_application_run
    at gapplication.c line 2114
  • #11 main
    at totem.c line 282

==============

From a quick check, other (segfault-free) channels don't have the "UNAVAILABLE" stuff:

Breakpoint 1, can_remove (source=0x1372390 [GrlLuaFactorySource], media=0xcd3900 [GrlMediaVideo]) at totem-grilo.c:340
340		scheme = g_uri_parse_scheme (url);
(gdb) print url
$1 = 0xff1440 "UNAVAILABLEUNAVAILABLE playpath=UNAVAILABLE swfVfy=1 swfUrl=http://euronews.com/media/player_live_1_14.swf live=1"
Comment 1 Bastien Nocera 2014-06-04 16:49:58 UTC
Created attachment 277888 [details] [review]
lua-factory: Fix broken URLs for Euronews outside Europe

From some locations, Euronews will not make all of its streams
available. This ensures that we filter out the streams that aren't
available.
Comment 2 Bastien Nocera 2014-06-04 16:50:11 UTC
I fixed the crash, but the source shouldn't give out those broken URLs:

commit aa00571190e1d8d7d4d379835e44b6b55a4c1b31
Author: Bastien Nocera <hadess@hadess.net>
Date:   Wed Jun 4 18:33:36 2014 +0200

    main: Fix crash when browsing Euronews source
    
    In some locations, because the Euronews source would give out broken
    URIs such as:
    UNAVAILABLEUNAVAILABLE playpath=UNAVAILABLE swfVfy=1 swfUrl=http://euronews.com/media/player_live_1_14.swf live=1
    
    https://bugzilla.gnome.org/show_bug.cgi?id=731224
Comment 3 Bastien Nocera 2014-06-04 16:51:38 UTC
Can you please test the attached patch against grilo-plugins? Applying it to:
/usr/share/grilo-plugins/grl-lua-factory/grl-euronews.lua
should be enough to test this if you don't want to rebuild the whole thing.
Comment 4 Joanmarie Diggs (IRC: joanie) 2014-06-04 17:48:01 UTC
(In reply to comment #3)
> Can you please test the attached patch against grilo-plugins? Applying it to:
> /usr/share/grilo-plugins/grl-lua-factory/grl-euronews.lua
> should be enough to test this if you don't want to rebuild the whole thing.

Yup, that works: No crash and I have access to Euronews Persian. :)
Comment 5 Bastien Nocera 2014-06-04 17:50:12 UTC
(In reply to comment #4)
> (In reply to comment #3)
> > Can you please test the attached patch against grilo-plugins? Applying it to:
> > /usr/share/grilo-plugins/grl-lua-factory/grl-euronews.lua
> > should be enough to test this if you don't want to rebuild the whole thing.
> 
> Yup, that works: No crash and I have access to Euronews Persian. :)

Geoblocking :/
Comment 6 Juan A. Suarez Romero 2014-06-04 18:24:03 UTC
Attachment 277888 [details] pushed as 15443d2 - lua-factory: Fix broken URLs for Euronews outside Europe