From 2622a439b1e3598469ca1390607b33e21e7504b4 Mon Sep 17 00:00:00 2001 From: Mirek Skoczek Date: Thu, 1 Feb 2024 13:34:02 +0100 Subject: [PATCH] do not crash on empty seconds in DSS module --- getid3/module.audio.dss.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/getid3/module.audio.dss.php b/getid3/module.audio.dss.php index dd2a56b1..82a979a5 100644 --- a/getid3/module.audio.dss.php +++ b/getid3/module.audio.dss.php @@ -83,11 +83,11 @@ public function Analyze() { */ public function DSSdateStringToUnixDate($datestring) { $y = (int) substr($datestring, 0, 2); - $m = substr($datestring, 2, 2); - $d = substr($datestring, 4, 2); - $h = substr($datestring, 6, 2); - $i = substr($datestring, 8, 2); - $s = substr($datestring, 10, 2); + $m = (int) substr($datestring, 2, 2); + $d = (int) substr($datestring, 4, 2); + $h = (int) substr($datestring, 6, 2); + $i = (int) substr($datestring, 8, 2); + $s = (int) substr($datestring, 10, 2); $y += (($y < 95) ? 2000 : 1900); return mktime($h, $i, $s, $m, $d, $y); }