Skip to content
  • Danny Hindson's avatar
    Handle case where detector doesn't have a workspace index · fc91dd56
    Danny Hindson authored
    The unit tests SetCrystalLocationTest, LoadEventNexusTest were failing due to
    some detectors in the input nexus file not having a corresponding workspace
    index. This showed up as the pixelID_to_wi_vector vector having
    std::numeric_limits<size_t>::max() as the wi value
    I've added check that wi<numEventLists before trying to retrieve the spectrum
    for wi which is the same check that's done elsewhere in ProcessBankData.cpp
    If the file BSS_11841_event.nxs had been loaded with compression on
    this would have caused a crash even before my fix to the sort order