summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--apps/gui/gwps-common.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/gui/gwps-common.c b/apps/gui/gwps-common.c
index d43f56f..2c5238b 100644
--- a/apps/gui/gwps-common.c
+++ b/apps/gui/gwps-common.c
@@ -849,6 +849,9 @@ static char *get_token_value(struct gui_wps *gwps,
return buf;
case WPS_TOKEN_TRACK_ELAPSED_PERCENT:
+ if (id3->length <= 0)
+ return NULL;
+
if (intval)
{
*intval = limit * (id3->elapsed + state->ff_rewind_count)