Fixed a bug in mgl.pl (input with spaces was processed wrongly)