mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-09-13 02:42:09 +02:00
Fix build with ENABLE_DBUS=OFF
This commit is contained in:
@@ -45,12 +45,16 @@ static void getKDE(FFstrbuf* result, FFDEOptions* options)
|
||||
|
||||
static const char* getGnomeBySo(FFstrbuf* result)
|
||||
{
|
||||
#ifdef FF_HAVE_DBUS
|
||||
FFDBusData dbus;
|
||||
if (ffDBusLoadData(DBUS_BUS_SESSION, &dbus) != NULL)
|
||||
return "ffDBusLoadData() failed";
|
||||
|
||||
ffDBusGetPropertyString(&dbus, "org.gnome.Shell", "/org/gnome/Shell", "org.gnome.Shell", "ShellVersion", result);
|
||||
return NULL;
|
||||
#else // FF_HAVE_DBUS
|
||||
return "ffDBusLoadData() failed: dbus support not compiled in";
|
||||
#endif // FF_HAVE_DBUS
|
||||
}
|
||||
|
||||
static void getGnome(FFstrbuf* result, FF_MAYBE_UNUSED FFDEOptions* options)
|
||||
|
||||
Reference in New Issue
Block a user