Fix a bug for sed in mac