Print

Print


URL:
  <http://savannah.cern.ch/bugs/?82132>

                 Summary: CheckHostDomain in XrdClientConn is not thread-safe
                 Project: XROOTD
            Submitted by: abh
            Submitted on: 2011-05-11 22:32
                Severity: 4 - Important
                Priority: 5 - Normal
                  Status: None
                 Privacy: Public
             Assigned to: ljanyst
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
      Fixed by commit(s): 

    _______________________________________________________

Details:

In method CheckHostDomain() in XrdClientConn.cc is called by Open() in
XrdClient without holding a global mutex. Unfortunately, CheckHostDomain()
may try to add entries to a static hash table. This invariably causes
corrupted memory with loops, hangs, or crashes.

Suggest fix; which was tried by LSST and appears to work, is to declare an
XrdSysMutexHelper object using a static mutex at entry to CheckHostDomain().
This will serialize access to the static hash table and solve the problem.




    _______________________________________________________

Reply to this item at:

  <http://savannah.cern.ch/bugs/?82132>

_______________________________________________
  Message sent via/by LCG Savannah
  http://savannah.cern.ch/