Commons IO
  1. Commons IO
  2. IO-217

FileUtils.copyDirectoryToDirectory makes infinite loops

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.4
    • Fix Version/s: 2.0
    • Component/s: None
    • Labels:
      None
    • Environment:

      Windows XP

      Description

      When using FileUtils.copyDirectoryToDirectory, infinite loops has occurred.

      – detail –
      src directory : D:\a
      dest directory : D:\a
      call : FileUtils.copyDirectoryToDirectory(new File("D:\a"), new File("D:\a"));
      expected result : directory D:\a\a will be created
      actual result : D:\a\a\a\a....... was created

      i guess FileUtils.copyDirectoryToDirectory causes of this result.
      ("destDir.mkdir()" is done before "srcDir.listFiles()")

      am i calling wrong method?

      thank you.

        Activity

        tora yamada created issue -
        Niall Pemberton made changes -
        Field Original Value New Value
        Fix Version/s 2.0 [ 12312961 ]
        Roun Lee made changes -
        Attachment FileUtilsPatch.txt [ 12453383 ]
        Niall Pemberton made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Assignee Niall Pemberton [ niallp ]
        Resolution Fixed [ 1 ]
        Mark Thomas made changes -
        Workflow jira [ 12473898 ] Default workflow, editable Closed status [ 12601894 ]
        Henri Yandell made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Niall Pemberton
            Reporter:
            tora yamada
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development