Avoid calling XOpenDisplay multiple times, fixes crashes on Intel Mesa

* See https://bugs.freedesktop.org/show_bug.cgi?id=99831
  https://bugs.freedesktop.org/show_bug.cgi?id=54971
* It's not clear if it's invalid to call XOpenDisplay more than once but
  at the very least it's only really used as convenience to avoid
  plumbing the display handle through.
This commit is contained in:
baldurk
2017-05-30 12:02:00 +01:00
parent 34112696e6
commit 3ab7510c7f
15 changed files with 150 additions and 83 deletions
+1 -2
View File
@@ -24,7 +24,6 @@
#include "renderdoccmd.h"
#include <locale.h>
#include <replay/renderdoc_replay.h>
#include <string.h>
#include <unistd.h>
#include <string>
@@ -116,7 +115,7 @@ void handle_cmd(android_app *app, int32_t cmd)
vector<string> args = getRenderdoccmdArgs();
if(!args.size())
break; // Nothing for APK to do.
renderdoccmd(args);
renderdoccmd(GlobalEnvironment(), args);
break;
}
case APP_CMD_TERM_WINDOW: break;