Proper userdata handling