[vlc-commits] upnp: use vlc_tick_from_sec() for more explicit conversion

Steve Lhomme git at videolan.org
Thu Jul 5 16:57:43 CEST 2018


vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Wed Jun 13 11:40:36 2018 +0200| [e8cff9b43022219758577988ce9b3f5b84448d2f] | committer: Steve Lhomme

upnp: use vlc_tick_from_sec() for more explicit conversion

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e8cff9b43022219758577988ce9b3f5b84448d2f
---

 modules/services_discovery/upnp.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/services_discovery/upnp.cpp b/modules/services_discovery/upnp.cpp
index 6708ca75f6..c5e51c3b1b 100644
--- a/modules/services_discovery/upnp.cpp
+++ b/modules/services_discovery/upnp.cpp
@@ -870,7 +870,7 @@ namespace
             {
                 int i_hours, i_minutes, i_seconds;
                 if( sscanf( psz_duration, "%d:%02d:%02d", &i_hours, &i_minutes, &i_seconds ) )
-                    i_duration = CLOCK_FREQ * ( i_hours * 3600 + i_minutes * 60 +
+                    i_duration = vlc_tick_from_sec( i_hours * 3600 + i_minutes * 60 +
                                                 i_seconds );
             }
             return input_item_NewExt( psz_resource_url, title, i_duration,



More information about the vlc-commits mailing list