Fixed bug in ilaenv