Bug 44233 - Не правильно указаны require_once в pear-Net_SMPP_Client
Summary: Не правильно указаны require_once в pear-Net_SMPP_Client
Status: NEW
Alias: None
Product: Sisyphus
Classification: Development
Component: pear-Net_SMPP_Client (show other bugs)
Version: unstable
Hardware: x86_64 Linux
: P5 normal
Assignee: Nikolay A. Fetisov
QA Contact: qa-sisyphus
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-11-07 19:54 MSK by Alexandr Shashkin
Modified: 2022-11-07 19:54 MSK (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandr Shashkin 2022-11-07 19:54:12 MSK
Версия программы:
=================
pear-Net_SMPP_Client-0.4.1-alt2

Шаги, приводящие к ошибке:
==========================
1) Установить php8.1, pear-core, pear-Net_SMPP_Client
2) Создать файл instance.php со следующим содержимым:
<?php
require_once 'Net/SMPP/Client.php';
$smsc = new Net_SMPP_Client('smpp.example.com', 3204);
echo "success\n";
?>
3) Выполнить его: php8.1 instance.php

Результат:
==========
PHP Warning:  require_once(Net/SMPP.php): Failed to open stream: No such file or directory in /usr/share/php/pear/Net/SMPP/Client.php on line 29
PHP Fatal error:  Uncaught Error: Failed opening required 'Net/SMPP.php' (include_path='./:/usr/lib64/php/:/usr/lib64/php/8.1.12/:/usr/share/php/pear/:/usr/share/php/modules/:/usr/share/php/8.1.12/modules/') in /usr/share/php/pear/Net/SMPP/Client.php:29
Stack trace:
#0 /home/test/instance.php(2): require_once()
#1 {main}
  thrown in /usr/share/php/pear/Net/SMPP/Client.php on line 29

Ожидаемый результат:
====================
В файле /usr/share/php/pear/Net/SMPP/Client.php вместо Net/SMPP.php и Net/SMPP/Vendor.php в require_once указаны Net/Net/SMPP.php и Net/Net/SMPP/Vendor.php. Так как php файлы модуля pear-Net_SMPP лежат в /usr/share/php/pear/Net/Net