bugfixes: use pointer for Unmarshal, set capacity not length