{"action":"created","issue":{"url":"https://api.github.com/repos/ValveSoftware/openvr/issues/59","repository_url":"https://api.github.com/repos/ValveSoftware/openvr","labels_url":"https://api.github.com/repos/ValveSoftware/openvr/issues/59/labels{/name}","comments_url":"https://api.github.com/repos/ValveSoftware/openvr/issues/59/comments","events_url":"https://api.github.com/repos/ValveSoftware/openvr/issues/59/events","html_url":"https://github.com/ValveSoftware/openvr/issues/59","id":136996048,"node_id":"MDU6SXNzdWUxMzY5OTYwNDg=","number":59,"title":"Segfault in dl_close when calling vr::VR_Init() on linux","user":{"login":"slowriot","id":649131,"node_id":"MDQ6VXNlcjY0OTEzMQ==","avatar_url":"https://avatars1.githubusercontent.com/u/649131?v=4","gravatar_id":"","url":"https://api.github.com/users/slowriot","html_url":"https://github.com/slowriot","followers_url":"https://api.github.com/users/slowriot/followers","following_url":"https://api.github.com/users/slowriot/following{/other_user}","gists_url":"https://api.github.com/users/slowriot/gists{/gist_id}","starred_url":"https://api.github.com/users/slowriot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/slowriot/subscriptions","organizations_url":"https://api.github.com/users/slowriot/orgs","repos_url":"https://api.github.com/users/slowriot/repos","events_url":"https://api.github.com/users/slowriot/events{/privacy}","received_events_url":"https://api.github.com/users/slowriot/received_events","type":"User","site_admin":false},"labels":[{"id":595574685,"node_id":"MDU6TGFiZWw1OTU1NzQ2ODU=","url":"https://api.github.com/repos/ValveSoftware/openvr/labels/Need%20Retest","name":"Need Retest","color":"e99695","default":false}],"state":"closed","locked":false,"assignee":{"login":"Plagman","id":529930,"node_id":"MDQ6VXNlcjUyOTkzMA==","avatar_url":"https://avatars3.githubusercontent.com/u/529930?v=4","gravatar_id":"","url":"https://api.github.com/users/Plagman","html_url":"https://github.com/Plagman","followers_url":"https://api.github.com/users/Plagman/followers","following_url":"https://api.github.com/users/Plagman/following{/other_user}","gists_url":"https://api.github.com/users/Plagman/gists{/gist_id}","starred_url":"https://api.github.com/users/Plagman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Plagman/subscriptions","organizations_url":"https://api.github.com/users/Plagman/orgs","repos_url":"https://api.github.com/users/Plagman/repos","events_url":"https://api.github.com/users/Plagman/events{/privacy}","received_events_url":"https://api.github.com/users/Plagman/received_events","type":"User","site_admin":false},"assignees":[{"login":"Plagman","id":529930,"node_id":"MDQ6VXNlcjUyOTkzMA==","avatar_url":"https://avatars3.githubusercontent.com/u/529930?v=4","gravatar_id":"","url":"https://api.github.com/users/Plagman","html_url":"https://github.com/Plagman","followers_url":"https://api.github.com/users/Plagman/followers","following_url":"https://api.github.com/users/Plagman/following{/other_user}","gists_url":"https://api.github.com/users/Plagman/gists{/gist_id}","starred_url":"https://api.github.com/users/Plagman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Plagman/subscriptions","organizations_url":"https://api.github.com/users/Plagman/orgs","repos_url":"https://api.github.com/users/Plagman/repos","events_url":"https://api.github.com/users/Plagman/events{/privacy}","received_events_url":"https://api.github.com/users/Plagman/received_events","type":"User","site_admin":false}],"milestone":null,"comments":11,"created_at":"2016-02-28T02:36:05Z","updated_at":"2018-12-21T14:06:18Z","closed_at":"2018-12-21T14:06:18Z","author_association":"NONE","body":"A very simple hello world program (on a system with no HMD) returns true for `vr::VR_IsHmdPresent()` but then segfaults in the call to `vr::VR_Init()`.\n\nSystem is linux, amd64, C++ test program built with GCC 5.3.1.\n\nTest program that reproduces the error:\n\n```\n// Build with g++ -std=c++11 openvrtest.cpp -L. -lopenvr_api -Iinclude -o openvrtest\n#include <iostream>\n#include \"openvr.h\"\n\nauto main()->int {\n  if(vr::VR_IsHmdPresent()) {\n    std::cout << \"No head mounted display present.\" << std::endl;\n    return EXIT_SUCCESS;\n  }\n  std::cout << \"Head mounted display may be present, initialising...\" << std::endl;\n  vr::EVRInitError vr_error = vr::VRInitError_None;\n  vr::IVRSystem *hmd_handle = vr::VR_Init(&vr_error, vr::VRApplication_Scene);\n  std::cout << \"Initialised successfully\" << std::endl;\n  return EXIT_SUCCESS;\n}\n```\n\nProduces the output and segfault:\n\n```\nHead mounted display may be present, initialising...\n\nProgram received signal SIGSEGV, Segmentation fault.\n_dl_close (_map=0x0) at dl-close.c:762\n762 dl-close.c: No such file or directory.\n(gdb) bt\n#0  _dl_close (_map=0x0) at dl-close.c:762\n#1  0x00007ffff7dea114 in _dl_catch_error (objname=0x613c30, errstring=0x613c38, mallocedp=0x613c28, \n    operate=0x7ffff6b43fd0 <dlclose_doit>, args=0x0) at dl-error.c:187\n#2  0x00007ffff6b444d9 in _dlerror_run (operate=operate@entry=0x7ffff6b43fd0 <dlclose_doit>, args=0x0) at dlerror.c:163\n#3  0x00007ffff6b43fff in __dlclose (handle=<optimized out>) at dlclose.c:46\n#4  0x00007ffff7b92fcb in vr::VR_InitInternal (peError=0x7fffffffe62c, eApplicationType=vr::VRApplication_Scene)\n    at openvr_api.cpp:45\n#5  0x0000000000400d3b in vr::VR_Init(vr::EVRInitError*, vr::EVRApplicationType) ()\n#6  0x0000000000400b5e in main ()\n```\n"},"comment":{"url":"https://api.github.com/repos/ValveSoftware/openvr/issues/comments/449397200","html_url":"https://github.com/ValveSoftware/openvr/issues/59#issuecomment-449397200","issue_url":"https://api.github.com/repos/ValveSoftware/openvr/issues/59","id":449397200,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0OTM5NzIwMA==","user":{"login":"kisak-valve","id":24358216,"node_id":"MDQ6VXNlcjI0MzU4MjE2","avatar_url":"https://avatars0.githubusercontent.com/u/24358216?v=4","gravatar_id":"","url":"https://api.github.com/users/kisak-valve","html_url":"https://github.com/kisak-valve","followers_url":"https://api.github.com/users/kisak-valve/followers","following_url":"https://api.github.com/users/kisak-valve/following{/other_user}","gists_url":"https://api.github.com/users/kisak-valve/gists{/gist_id}","starred_url":"https://api.github.com/users/kisak-valve/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kisak-valve/subscriptions","organizations_url":"https://api.github.com/users/kisak-valve/orgs","repos_url":"https://api.github.com/users/kisak-valve/repos","events_url":"https://api.github.com/users/kisak-valve/events{/privacy}","received_events_url":"https://api.github.com/users/kisak-valve/received_events","type":"User","site_admin":false},"created_at":"2018-12-21T14:06:18Z","updated_at":"2018-12-21T14:06:18Z","author_association":"MEMBER","body":"Closing per the last comment."}}
{"actor":{"display_login":"kisak-valve"}}