Fixed bug in way sed -i option used