{"action":"created","issue":{"url":"https://api.github.com/repos/LaurentGomila/CSFML/issues/59","labels_url":"https://api.github.com/repos/LaurentGomila/CSFML/issues/59/labels{/name}","comments_url":"https://api.github.com/repos/LaurentGomila/CSFML/issues/59/comments","events_url":"https://api.github.com/repos/LaurentGomila/CSFML/issues/59/events","html_url":"https://github.com/LaurentGomila/CSFML/pull/59","id":58768861,"number":59,"title":"Added support for joystick identification","user":{"login":"zsbzsb","id":3647990,"avatar_url":"https://avatars.githubusercontent.com/u/3647990?v=3","gravatar_id":"","url":"https://api.github.com/users/zsbzsb","html_url":"https://github.com/zsbzsb","followers_url":"https://api.github.com/users/zsbzsb/followers","following_url":"https://api.github.com/users/zsbzsb/following{/other_user}","gists_url":"https://api.github.com/users/zsbzsb/gists{/gist_id}","starred_url":"https://api.github.com/users/zsbzsb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zsbzsb/subscriptions","organizations_url":"https://api.github.com/users/zsbzsb/orgs","repos_url":"https://api.github.com/users/zsbzsb/repos","events_url":"https://api.github.com/users/zsbzsb/events{/privacy}","received_events_url":"https://api.github.com/users/zsbzsb/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-02-24T17:05:08Z","updated_at":"2015-02-24T18:32:10Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/LaurentGomila/CSFML/pulls/59","html_url":"https://github.com/LaurentGomila/CSFML/pull/59","diff_url":"https://github.com/LaurentGomila/CSFML/pull/59.diff","patch_url":"https://github.com/LaurentGomila/CSFML/pull/59.patch"},"body":"What a big white box this is....\r\n\r\nLets fill it with https://github.com/LaurentGomila/SFML/commit/29c0f1491177d9125cc731f0c04bdf4c21c4650e"},"comment":{"url":"https://api.github.com/repos/LaurentGomila/CSFML/issues/comments/75816286","html_url":"https://github.com/LaurentGomila/CSFML/pull/59#issuecomment-75816286","issue_url":"https://api.github.com/repos/LaurentGomila/CSFML/issues/59","id":75816286,"user":{"login":"zsbzsb","id":3647990,"avatar_url":"https://avatars.githubusercontent.com/u/3647990?v=3","gravatar_id":"","url":"https://api.github.com/users/zsbzsb","html_url":"https://github.com/zsbzsb","followers_url":"https://api.github.com/users/zsbzsb/followers","following_url":"https://api.github.com/users/zsbzsb/following{/other_user}","gists_url":"https://api.github.com/users/zsbzsb/gists{/gist_id}","starred_url":"https://api.github.com/users/zsbzsb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zsbzsb/subscriptions","organizations_url":"https://api.github.com/users/zsbzsb/orgs","repos_url":"https://api.github.com/users/zsbzsb/repos","events_url":"https://api.github.com/users/zsbzsb/events{/privacy}","received_events_url":"https://api.github.com/users/zsbzsb/received_events","type":"User","site_admin":false},"created_at":"2015-02-24T18:32:10Z","updated_at":"2015-02-24T18:32:10Z","body":"I thought about that, but then I remembered we are in pre C++11 era. So there really isn't any hashmap we could use. Also I talked to @binary1248 and was told it is a generally accepted standard that any calls to a C function invalidates the previous returned pointers/values.\r\n\r\nBut if you can tell me a good way to store a specific string per id that doesn't involve copying the string when adding another id I'm all ears. I personally thought about using a vector but that may end up copying the strings and invalidating the pointer from c_str()... :(\r\n\r\nhttp://en.cppreference.com/w/c/program/getenv\r\n>This function is not required to be thread-safe. Another call to getenv, as well as a call to the POSIX functions setenv(), unsetenv(), and putenv() may invalidate the pointer returned by a previous call or modify the string obtained from a previous call. \r\nhttp://en.cppreference.com/w/c/chrono/ctime\r\n> pointer to a static null-terminated character string holding the textual representation of date and time. The string may be shared between asctime and ctime, and may be overwritten on each invocation of any of those functions."}}