Compilation on clang failed as we would try to jump to the 'out' label and then jump over the initialization of a variable with __attribute__((cleanup)). We move the initaliztion up to make sure it happens before the goto.