fix line parsing