r20336: Fix some memleaks in trans2open and simplify trans2mkdir a bit: We now have