debugger fixed, where entry have not always a file name. 25/21625/2
Cedric Delamarre [Wed, 18 Nov 2020 13:38:23 +0000 (14:38 +0100)]
Change-Id: I1abef250955919c0eebcea28f374665952d760ae

scilab/modules/ast/src/cpp/ast/debuggervisitor.cpp

index fffeef8..38d67da 100644 (file)
@@ -477,6 +477,11 @@ bool getMacroSourceFile(std::string* filename)
         return false;
     }
 
+    if(lWhereAmI.back().m_file_name == nullptr)
+    {
+        return false;
+    }
+
     std::string file = scilab::UTF8::toUTF8(*lWhereAmI.back().m_file_name);
     if (file.rfind(".bin") != std::string::npos)
     {
@@ -494,4 +499,4 @@ bool getMacroSourceFile(std::string* filename)
     }
 
     return true;
-}
\ No newline at end of file
+}