added multiline and xml support to ffGetPropValue

This commit is contained in:
Linus Dierheimer
2021-05-16 18:41:00 +02:00
parent 5f71ef71da
commit c8a9f06b52
2 changed files with 49 additions and 26 deletions
-3
View File
@@ -236,13 +236,10 @@ static void getMate(FFinstance* instance, FFWMDEResult* result)
//I parse the file 3 times by purpose, because the properties are not guaranteed to be in order
ffParsePropFile("/usr/share/mate-about/mate-version.xml", "<platform>", &result->deVersion);
ffStrbufSubstrBeforeFirstC(&result->deVersion, '<');
ffStrbufAppendC(&result->deVersion, '.');
ffParsePropFile("/usr/share/mate-about/mate-version.xml", "<minor>", &result->deVersion);
ffStrbufSubstrBeforeFirstC(&result->deVersion, '<');
ffStrbufAppendC(&result->deVersion, '.');
ffParsePropFile("/usr/share/mate-about/mate-version.xml", "<micro>", &result->deVersion);
ffStrbufSubstrBeforeFirstC(&result->deVersion, '<');
if(result->deVersion.length == 0 && instance->config.allowSlowOperations)
{