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

Coverity #1395811 Time of check time of use

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor - P4
    • Resolution: Fixed
    • None
    • 4.0.4, 4.1.4, WT3.2.0
    • None
    • None
    • 1
    • Storage Engines 2018-10-08

    Description

      Coverity #1395811 Time of check time of use

      37. Condition (__r = __wt_snprintf(fromfile, 4096UL /* sizeof (fromfile) */, "%s/%s", fromdir, dp->d_name)) != 0, taking true branch.
              testutil_check(__wt_snprintf(fromfile, sizeof(fromfile),
              "%s/%s", fromdir, dp->d_name));
       38. Condition (__r = __wt_snprintf(tofile, 4096UL /* sizeof (tofile) */, "%s/%s", todir, dp->d_name)) != 0, taking true branch.
              testutil_check(__wt_snprintf(tofile, sizeof(tofile),
              "%s/%s", todir, dp->d_name));  	
      CID 1395811 (#1 of 1): Time of check time of use (TOCTOU)
      39. fs_check_call: Calling function stat to perform check on fromfile.
      40. Condition (__r = stat(fromfile, &sb)) != 0, taking true branch.
              testutil_check(stat(fromfile, &sb));
      

      Attachments

        Activity

          People

            keith.bostic@mongodb.com Keith Bostic (Inactive)
            keith.bostic@mongodb.com Keith Bostic (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: