[Bug 730830] hlsdemux: Remove \" sign from decryption KEY url does not always work
GStreamer (bugzilla.gnome.org)
bugzilla at gnome.org
Tue May 27 07:54:33 PDT 2014
https://bugzilla.gnome.org/show_bug.cgi?id=730830
GStreamer | gst-plugins-bad | 1.3.2
Sebastian Dröge (slomo) <slomo> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #277304|none |needs-work
status| |
--- Comment #1 from Sebastian Dröge (slomo) <slomo at coaxion.net> 2014-05-27 14:54:27 UTC ---
Review of attachment 277304:
--> (https://bugzilla.gnome.org/review?bug=730830&attachment=277304)
::: ext/hls/m3u8.c
@@ +424,3 @@
/* handle the \"uri\" case */
+ /* there are sometimes situations where we have white signs
+ * before or after \" sign of URL therefore we are using for loops
Maybe we should just remove spaces then? g_ascii_isspace() or something
@@ +426,3 @@
+ * before or after \" sign of URL therefore we are using for loops
+ * in order to remove first and last \" sign from decryption key URL
*/
+ for(guint i = 0; i < len; ++i){
Declare the variable outside the for loop at the beginning of the block. We
don't allow C99 yet :)
@@ +428,3 @@
+ for(guint i = 0; i < len; ++i){
+ if (uri[len - i] == '"'){
+ uri[len - i] = '\0';
if i == 0 you write to uri[len], which is one element after the end
@@ +432,3 @@
+ }
+ }
+ for(guint i = 0; i < len; ++i){
variable declaration
--
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list