This avoids memory leaks if there actually was some extradata set before. Signed-off-by: Martin Storsjö <martin@martin.st>