Commit 795d4567 authored by gbalduzz's avatar gbalduzz
Browse files

Fix possible division by 0 in CT-AUX updateShell.

parent 63654be6
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1545,7 +1545,8 @@ bool CtauxWalker<device_t, parameters_type, MOMS_type>::assert_exp_delta_V_value

template <dca::linalg::DeviceType device_t, class parameters_type, class MOMS_type>
void CtauxWalker<device_t, parameters_type, MOMS_type>::updateShell(const int done, const int total) {
  if (concurrency.id() == concurrency.first() && total > 10 && (done % (total / 10)) == 0) {
  const int milestone = std::max(total / 10, 1);
  if (concurrency.id() == concurrency.first() && (done % milestone == 0)) {
    std::cout.unsetf(std::ios_base::floatfield);

    std::cout << "\t\t\t" << std::setw(14)