cameradar_standalone/src/tasks/parsing.cpp
std::string
xml_safe_get(const TiXmlElement* elem, const std::string& attr) {
    if (elem == nullptr) return "closed";
    if (elem->Attribute(attr.c_str()) != nullptr) return std::string(elem->Attribute(attr.c_str()));
    return "closed";
}
// Avoids segfaults on unknown xml structure
Avoids segfaults on unknown xml structure
Avoids segfaults on unknown xml structure
std::string
xml_safe_get(const TiXmlElement* elem, const std::string& attr) {
    if (elem == nullptr) return "closed";
    if (elem->Attribute(attr.c_str()) != nullptr) return std::string(elem->Attribute(attr.c_str()));
    return "closed";
}
std :: string xml_safe_get ( const TiXmlElement * elem , const std :: string & attr ) { if ( elem == nullptr ) return " " ; if ( elem -> Attribute ( attr . c_str ( ) ) != nullptr ) return std :: string ( elem -> Attribute ( attr . c_str ( ) ) ) ; return " " ; }
Avoids segfaults on unknown xml structure
Avoids segfaults on unknown xml structure