Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-228

when saving file with gridfs, if the size is aligned with 256KB, then driver saves an extra chunk at the end with empty array

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • 2.4
    • None
    • None
    • None

    Description

      in GridFSInputFile.java, the loop creating chunks only ends when:
      ...
      if ( start < b.length )
      break;
      ...

      But it should also check if total == file length.
      Right now it does an extra loop.

      Attachments

        Activity

          People

            antoine Antoine Girbal
            antoine Antoine Girbal
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: