Fixed crash problem