Fix crash on releasing device (error was introduced when merging from trunk).


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code@4859 dfc29bdd-3216-0410-991c-e03cc46cb475