xd_doc: Change allocation convention
Use *doc instead of struct xd_doc for sizeof operator