From f8d0ebe92f9ceb4be761078395ef51a15fb0ae47 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Wed, 27 Aug 2014 19:06:50 +0200 Subject: [PATCH] PlayerThread: check if total_time is valid before using it --- src/PlayerThread.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PlayerThread.cxx b/src/PlayerThread.cxx index 1850a1711..00f8007a1 100644 --- a/src/PlayerThread.cxx +++ b/src/PlayerThread.cxx @@ -562,7 +562,7 @@ Player::SeekDecoder() /* send the SEEK command */ double where = pc.seek_where; - if (where > pc.total_time) + if (pc.total_time > 0 && where > pc.total_time) where = pc.total_time - 0.1; if (where < 0.0) where = 0.0;