Minor improvements (#249)

* Minor improvements

* Update CHANGELOG.md
This commit is contained in:
Roman Kelesidis 2023-09-18 00:11:24 +07:00 committed by GitHub
parent 5899e983bc
commit e5198f3092
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 9 additions and 5 deletions

View File

@ -7,7 +7,7 @@
- Release v2.1.5-2023.09 🎉
- Fixed cache directory auto-creating with SQLite [\#247](https://github.com/torrentpier/torrentpier-lts/pull/247) ([belomaxorka](https://github.com/belomaxorka))
- Minor improvements [\#245](https://github.com/torrentpier/torrentpier-lts/pull/245), [\#246](https://github.com/torrentpier/torrentpier-lts/pull/246), [\#248](https://github.com/torrentpier/torrentpier-lts/pull/248) ([belomaxorka](https://github.com/belomaxorka))
- Minor improvements [\#245](https://github.com/torrentpier/torrentpier-lts/pull/245), [\#246](https://github.com/torrentpier/torrentpier-lts/pull/246), [\#248](https://github.com/torrentpier/torrentpier-lts/pull/248), [\#249](https://github.com/torrentpier/torrentpier-lts/pull/249) ([belomaxorka](https://github.com/belomaxorka))
## [v2.1.5-2023.08-HotFix](https://github.com/torrentpier/torrentpier-lts/tree/v2.1.5-2023.08-HotFix) (2023-09-17)
[Full Changelog](https://github.com/torrentpier/torrentpier-lts/compare/v2.1.5-2023.08...v2.1.5-2023.08-HotFix)

View File

@ -252,7 +252,7 @@ if ($check_upload)
if (!$error)
{
if ( !($fp = @fopen($upload_dir . '/0_000000.000', 'wb')) )
if ( !($fp = @fopen($upload_dir . '/0_000000.000', 'wb+')) )
{
$error = TRUE;
$error_msg = sprintf($lang['DIRECTORY_NOT_WRITEABLE'], $attach_config['upload_dir']) . '<br />';
@ -441,7 +441,7 @@ if ($check_image_cat)
if (!$error)
{
if ( !($fp = @fopen($upload_dir . '/0_000000.000', 'wb')) )
if ( !($fp = @fopen($upload_dir . '/0_000000.000', 'wb+')) )
{
$error = TRUE;
$error_msg = sprintf($lang['DIRECTORY_NOT_WRITEABLE'], $upload_dir) . '<br />';

View File

@ -78,7 +78,11 @@ if (strlen($info_hash) != 20)
{
msg_die('Invalid info_hash: ' . bin2hex($info_hash));
}
if (!isset($peer_id) || strlen($peer_id) != 20)
if (!isset($peer_id))
{
msg_die('peer_id was not provided');
}
if (strlen($peer_id) != 20)
{
msg_die('Invalid peer_id: ' . bin2hex($peer_id));
}

View File

@ -118,7 +118,7 @@ $bb_cfg['bt_min_ratio_warning'] = 0.6; // 0 - disable
$tr_cfg = array(
'autoclean' => true,
'off' => false,
'off_reason' => 'temporarily disabled',
'off_reason' => 'Temporarily disabled',
'numwant' => 50,
'update_dlstat' => true,
'expire_factor' => 2.5,