removing bogus padding