OS: remove option --escape-bedrock

This commit is contained in:
Carter Li
2025-02-12 08:53:27 +08:00
parent f77a9c185d
commit 3e3dfb4a02
4 changed files with 1 additions and 20 deletions
-10
View File
@@ -104,16 +104,6 @@
"default": true
}
},
{
"long": "escape-bedrock",
"desc": "On Bedrock Linux, whether to escape the bedrock jail",
"remark": "Linux only",
"arg": {
"type": "bool",
"optional": true,
"default": true
}
},
{
"long": "wmi-timeout",
"desc": "Set the timeout (ms) for WMI queries",
+1 -1
View File
@@ -261,7 +261,7 @@ static void detectOS(FFOSResult* os)
return;
#endif
if(instance.config.general.escapeBedrock && parseOsRelease(FASTFETCH_TARGET_DIR_ROOT "/bedrock" FASTFETCH_TARGET_DIR_ETC "/bedrock-release", os))
if(parseOsRelease(FASTFETCH_TARGET_DIR_ROOT "/bedrock" FASTFETCH_TARGET_DIR_ETC "/bedrock-release", os))
{
if(os->id.length == 0)
ffStrbufAppendS(&os->id, "bedrock");
-8
View File
@@ -31,8 +31,6 @@ const char* ffOptionsParseGeneralJsonConfig(FFOptionsGeneral* options, yyjson_va
options->detectVersion = yyjson_get_bool(val);
#if defined(__linux__) || defined(__FreeBSD__) || defined(__sun) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__HAIKU__)
else if (ffStrEqualsIgnCase(key, "escapeBedrock"))
options->escapeBedrock = yyjson_get_bool(val);
else if (ffStrEqualsIgnCase(key, "playerName"))
ffStrbufSetS(&options->playerName, yyjson_get_str(val));
else if (ffStrEqualsIgnCase(key, "dsForceDrm"))
@@ -76,8 +74,6 @@ bool ffOptionsParseGeneralCommandLine(FFOptionsGeneral* options, const char* key
options->detectVersion = ffOptionParseBoolean(value);
#if defined(__linux__) || defined(__FreeBSD__) || defined(__sun) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__HAIKU__)
else if(ffStrEqualsIgnCase(key, "--escape-bedrock"))
options->escapeBedrock = ffOptionParseBoolean(value);
else if(ffStrEqualsIgnCase(key, "--player-name"))
ffOptionParseString(key, value, &options->playerName);
else if(ffStrEqualsIgnCase(key, "--ds-force-drm"))
@@ -107,7 +103,6 @@ void ffOptionsInitGeneral(FFOptionsGeneral* options)
options->detectVersion = true;
#if defined(__linux__) || defined(__FreeBSD__) || defined(__sun) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__HAIKU__)
options->escapeBedrock = true;
ffStrbufInit(&options->playerName);
options->dsForceDrm = FF_DS_FORCE_DRM_TYPE_FALSE;
#elif defined(_WIN32)
@@ -137,9 +132,6 @@ void ffOptionsGenerateGeneralJsonConfig(FFOptionsGeneral* options, yyjson_mut_do
#if defined(__linux__) || defined(__FreeBSD__) || defined(__sun) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__HAIKU__)
if (options->escapeBedrock != defaultOptions.escapeBedrock)
yyjson_mut_obj_add_bool(doc, obj, "escapeBedrock", options->escapeBedrock);
if (!ffStrbufEqual(&options->playerName, &defaultOptions.playerName))
yyjson_mut_obj_add_strbuf(doc, obj, "playerName", &options->playerName);
-1
View File
@@ -18,7 +18,6 @@ typedef struct FFOptionsGeneral
// Module options that cannot be put in module option structure
#if defined(__linux__) || defined(__FreeBSD__) || defined(__sun) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__HAIKU__)
FFstrbuf playerName;
bool escapeBedrock;
FFDsForceDrmType dsForceDrm;
#elif defined(_WIN32)
int32_t wmiTimeout;