Some fixes for nvidia. (forgot to zero some variables)