Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-14334

Unused variable inside __wti_txn_log_commit

    • Type: Icon: Task Task
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Transactions
    • Storage Engines
    • 1
    • StorEng - Defined Pipeline

      The following code inside txn_log.c shows no usage of an argument that is passed into the function follow:

      /*
       * __wti_txn_log_commit --
       *     Write the operations of a transaction to the log at commit time.
       */
      int
      __wti_txn_log_commit(WT_SESSION_IMPL *session, const char *cfg[])
      {
          WT_TXN *txn;
      
          WT_UNUSED(cfg);
          txn = session->txn;
          /*
           * If there are no log records there is nothing to do.
           */
          if (txn->logrec == NULL)
              return (0);
      
          /* Write updates to the log. */
          return (__wt_log_write(session, txn->logrec, NULL, txn->txn_logsync));
      }
      

      This ticket will remove the unused cfg variable.

            Assignee:
            backlog-server-storage-engines [DO NOT USE] Backlog - Storage Engines Team
            Reporter:
            jie.chen@mongodb.com Jie Chen
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: