From 0742ed33f8ab5c17f8d7b0ec5e1f48d97fd150b0 Mon Sep 17 00:00:00 2001 From: xiaomlove Date: Fri, 14 May 2021 01:20:41 +0800 Subject: [PATCH] fix torrent_info.php 404 --- public/torrent_info.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/public/torrent_info.php b/public/torrent_info.php index cdda67a8..02332df0 100644 --- a/public/torrent_info.php +++ b/public/torrent_info.php @@ -9,7 +9,7 @@ function print_array($array, $offset_symbol = "|--", $offset = "", $parent = "") echo "[$array] is not an array!
"; return; } - + reset($array); switch($array['type'] ?? '') @@ -48,12 +48,12 @@ function print_array($array, $offset_symbol = "|--", $offset = "", $parent = "") //echo $offset; print_array($val, $offset_symbol, $offset, $key); } - } + } break; - + } - -} + +} dbconn(); @@ -72,7 +72,7 @@ if (!$id) $res = sql_query("SELECT name FROM torrents WHERE id = ".sqlesc($id)) or sqlerr(__FILE__, __LINE__); $row = mysql_fetch_assoc($res); -$fn = "$torrent_dir/$id.torrent"; +$fn = getFullDirectory("$torrent_dir/$id.torrent"); if (!$row || !is_file($fn) || !is_readable($fn)) httperr();