test and fix set_header