Skip to content

Commit 6659957

Browse files
authored
PR #13388 from AviaAv: add flush after printf on rs-fw-update
2 parents 9bba62e + 7d02b47 commit 6659957

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tools/fw-update/rs-fw-update.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@ void update(rs2::update_device fwu_dev, std::vector<uint8_t> fw_image)
109109
fwu_dev.update(fw_image, [&](const float progress)
110110
{
111111
printf("\rFirmware update progress: %d[%%]", (int)(progress * 100));
112+
std::cout.flush();
112113
});
113114
}
114115
else
@@ -425,6 +426,7 @@ try
425426
{
426427
flash = d.as< rs2::updatable >().create_flash_backup( [&]( const float progress ) {
427428
printf( "\rFlash backup progress: %d[%%]", (int)( progress * 100 ) );
429+
std::cout.flush();
428430
} );
429431
}
430432
else
@@ -488,6 +490,7 @@ try
488490
d.as<rs2::updatable>().update_unsigned( fw_image, [&]( const float progress )
489491
{
490492
printf( "\rFirmware update progress: %d[%%]", (int)( progress * 100 ) );
493+
std::cout.flush();
491494
} );
492495
}
493496
else

0 commit comments

Comments
 (0)