mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-26 23:13:00 +02:00
opkg_manager: Refactor version info saving logic in COPKGManager
Update logic in COPKGManager::pullPkgData() to handle various
package names including "neutrino-mp", "neutrino", or falling
back to the generic "PACKAGE" if specific names are not found.
Origin commit data
------------------
Branch: ni/coolstream
Commit: a48d607dab
Author: Thilo Graf <dbt@novatux.de>
Date: 2024-05-13 (Mon, 13 May 2024)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -945,7 +945,7 @@ void COPKGManager::pullPkgData()
|
|||||||
{
|
{
|
||||||
pkg_map[name].version = line.substr(9);
|
pkg_map[name].version = line.substr(9);
|
||||||
// Save version info for neutrino into file, for usage in other classes
|
// Save version info for neutrino into file, for usage in other classes
|
||||||
if (name == "neutrino-mp")
|
if (name == "neutrino-mp" || name == "neutrino" || name == PACKAGE || name == PACKAGE_NAME || name == PACKAGE_TARNAME)
|
||||||
{
|
{
|
||||||
std::ofstream outfile("/tmp/.neutrino.version");
|
std::ofstream outfile("/tmp/.neutrino.version");
|
||||||
outfile << pkg_map[name].version;
|
outfile << pkg_map[name].version;
|
||||||
|
Reference in New Issue
Block a user