Cleanup code in log_slot.c

XMLWordPrintableJSON

    • Storage Engines
    • 2024-08-06 - Withholding Tax
    • 2

      The code coverage task complains about the following:

      [2024/07/15 09:16:21.636] ./log/log_slot.c:698: warning: Non-matching opening bracket '{' detected.
      

      It seems to come from the following piece of code where we open a code block "twice" but only close once:

      #ifdef HAVE_DIAGNOSTIC
          diag_yield = (++log->write_calls % 7) == 0;
          if ((log->write_calls % WT_THOUSAND) == 0 || mysize > WT_LOG_SLOT_BUF_MAX) {
      #else
          diag_yield = false;
          if (mysize > WT_LOG_SLOT_BUF_MAX) {
      #endif
              unbuffered = true;
              F_SET(myslot, WT_MYSLOT_UNBUFFERED);
          }
      

              Assignee:
              Zunyi Liu
              Reporter:
              Etienne Petrel
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: