It's the library that was linked by Georgii - GLFW. It seems that Minecraft updated from LWJGL 2 to LWJGL 3, and the latter uses GLFW whereas the former doesn't. Right now it isn't fixed.
Honestly I might take a crack at debugging it later today, this is a really annoying bug that I'm afraid won't be fixed for a while due to the low amount of players experiencing the bug.
Woops, sorry. I thought the search function sorted reports by chronological order.
It would be GLFW as far as I can tell. Although for some reason I was unable to replicate the bug using the code here.