encode sys_call output