Uploaded image for project: 'ROOT'
  1. ROOT
  2. ROOT-3341

TXNetFile does not check return value of ReadV properly

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: 5.28/00
    • Fix Version/s: 6.08/00
    • Component/s: I/O
    • Labels:
      None
    • Environment:

      All

      Description

      Hi all,

      TXNetFile::ReadBuffers currently checks if XrdClient::ReadV returns a positive value. If it is positive, it treats the request as successful and returns.

      However, XrdClient::ReadV only returns the number of bytes it received from the server (and it may be smaller than the number of bytes requested). We've observed cases in CMS where the server reliably returns less bytes than requested (maybe 199 out of 201 buffers) on an valid file. In this case, ReadV returns a positive number but the last buffers are uninitialized. ROOT then returns successful but with uninitialized buffers.

      In CMS, we've been lucky and the returned data is unusable by TBasket and the application crashes.

      Regardless, TXNetFile::ReadBuffers and XrdClient::ReadV should agree on what the proper return code is for the "short read" case and act appropriately.

      Brian

        Attachments

          Activity

            People

            • Assignee:
              dhsmith David Smith
              Reporter:
              bbockelm Brian Paul Bockelman
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: