mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2024-11-10 06:02:09 +00:00
Fix wrong namespaces when using XML imports
This commit is contained in:
parent
68cad06ddf
commit
f0ec22e9b0
@ -197,7 +197,7 @@ class SymbolTableXmlMgr {
|
||||
String addrStr = element.getAttribute("ADDRESS");
|
||||
String namespace = element.getAttribute("NAMESPACE");
|
||||
if (namespace != null && namespace.endsWith("::")) {
|
||||
namespace = namespace.substring(namespace.length() - 2);
|
||||
namespace = namespace.substring(0, namespace.length() - 2);
|
||||
}
|
||||
String primary = element.getAttribute("PRIMARY");
|
||||
String sourceTypeString = element.getAttribute("SOURCE_TYPE");
|
||||
@ -233,13 +233,8 @@ class SymbolTableXmlMgr {
|
||||
scope = localNamespace;
|
||||
}
|
||||
else if (namespace != null && namespace.length() != 0) {
|
||||
if (program.getGlobalNamespace().equals(localNamespace)) {
|
||||
scope = NamespaceUtils.createNamespaceHierarchy(namespace,
|
||||
program.getGlobalNamespace(), program, sourceType);
|
||||
}
|
||||
else {
|
||||
name = namespace + name;
|
||||
}
|
||||
scope = NamespaceUtils.createNamespaceHierarchy(namespace,
|
||||
program.getGlobalNamespace(), program, sourceType);
|
||||
}
|
||||
|
||||
Symbol s = symbolTable.getPrimarySymbol(addr);
|
||||
|
Loading…
Reference in New Issue
Block a user