Fix potential crash when passing in NULL