Fix output fail with printf