small fix in sed func_sgwi