def do_string(data):
    """Emulate gmx_fio_do_string

    gmx_fio_do_string reads a string from a XDR file. On the contraty to the
    python unpack_string, gmx_fio_do_string reads the size as an unsigned
    interger before reading the actual string.

    See <gromacs-2016-src>/src/gromacs/fileio/gmx_system_xdr.c:454
    """
    data.unpack_int()
    return data.unpack_string()
