Fix sprintf problem that was the behavior undefined