diff options
| author | Tannin <devnull@localhost> | 2015-01-04 10:33:37 +0100 |
|---|---|---|
| committer | Tannin <devnull@localhost> | 2015-01-04 10:33:37 +0100 |
| commit | b415db619ed027ec2acd283983624293274b090f (patch) | |
| tree | 3b09112799f2728229ed98bca7b342f1e8d1232a /src/executableslist.cpp | |
| parent | bd8267993d1ed0292200f3052e3c30d4fc9c84f7 (diff) | |
| parent | b2d04d70fc6284797e1bf29f55a375cb59d012be (diff) | |
Merge
Diffstat (limited to 'src/executableslist.cpp')
| -rw-r--r-- | src/executableslist.cpp | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/src/executableslist.cpp b/src/executableslist.cpp index 7fd228d0..25b6bb0f 100644 --- a/src/executableslist.cpp +++ b/src/executableslist.cpp @@ -72,18 +72,20 @@ ExecutablesList::~ExecutablesList() void ExecutablesList::init(IPluginGame *game)
{
+ Q_ASSERT(game != nullptr);
m_Executables.clear();
for (const ExecutableInfo &info : game->executables()) {
- addExecutableInternal(info.title(),
- info.binary().absoluteFilePath(),
- info.arguments().join(" "),
- info.workingDirectory().absolutePath(),
- info.closeMO(),
- info.steamAppID());
+ if (info.isValid()) {
+ addExecutableInternal(info.title(),
+ info.binary().absoluteFilePath(),
+ info.arguments().join(" "),
+ info.workingDirectory().absolutePath(),
+ info.closeMO(),
+ info.steamAppID());
+ }
}
}
-
void ExecutablesList::getExecutables(std::vector<Executable>::iterator &begin, std::vector<Executable>::iterator &end)
{
begin = m_Executables.begin();
|
