mirror of
https://github.com/boykopovar/AnyPS5.git
synced 2026-10-22 08:33:12 -05:00
VLC (PPSA85300) imports daemon (Wn6I3wVATUE) and fails to load because no library exports it. Forking into the background is not supported, so it throws if called. VLC 3.0 calls daemon only when its daemon option is set, and the title starts libVLC with --ignore-config and without --daemon.
20 lines
658 B
C++
20 lines
658 B
C++
#include "prx/libc/include/general/VabiMacros.hpp"
|
|
#include <cstdlib>
|
|
#include <stdexcept>
|
|
#include <string>
|
|
extern "C" int APS5_VABI daemon_nid_postfix(int, int);
|
|
static void Require(bool value) { if (!value) std::abort(); }
|
|
static bool ReportsNotImplemented(int noChdir, int noClose) {
|
|
try {
|
|
daemon_nid_postfix(noChdir, noClose);
|
|
} catch (const std::runtime_error& error) {
|
|
return std::string(error.what()) == "daemon: forking into the background not implemented";
|
|
}
|
|
return false;
|
|
}
|
|
int main() {
|
|
Require(ReportsNotImplemented(1, 0));
|
|
Require(ReportsNotImplemented(0, 0));
|
|
Require(ReportsNotImplemented(1, 1));
|
|
}
|