removing trailing spaces in -m