Browse Source

Only use get_current_dir_name on Linux

Signed-off-by: falkTX <falktx@falktx.com>
pull/148/head
falkTX 5 years ago
parent
commit
4608cb7fc6
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      dgl/src/Window.cpp

+ 2
- 0
dgl/src/Window.cpp View File

@@ -1224,6 +1224,7 @@ bool Window::openFileBrowser(const FileBrowserOptions& options)

String startDir(options.startDir);

# ifdef DISTRHO_OS_LINUX
if (startDir.isEmpty())
{
if (char* const dir_name = get_current_dir_name())
@@ -1232,6 +1233,7 @@ bool Window::openFileBrowser(const FileBrowserOptions& options)
std::free(dir_name);
}
}
# endif

DISTRHO_SAFE_ASSERT_RETURN(startDir.isNotEmpty(), false);



Loading…
Cancel
Save