Disabling overcommit is not a solution, as often programs don't handle OOM and just report an error or outright crash, and it's possible that for instance system service wanted to allocate memory when your program took almost everything, and system is in unstable state now due to that.