X-Git-Url: https://git.siccegge.de//index.cgi?p=frida%2Ffrida.git;a=blobdiff_plain;f=src%2Fcore%2FFunction.cxx;h=4f8efe1622ea35b2ab23a133791eb349b728b0aa;hp=e31bce4a88481ea8952eb16dd384bf637cabfa92;hb=c81c0d3dba088b302187d7862a62ca88d2306e24;hpb=546b89382dd61b664c216ad7668ec783f0ad094c diff --git a/src/core/Function.cxx b/src/core/Function.cxx index e31bce4..4f8efe1 100644 --- a/src/core/Function.cxx +++ b/src/core/Function.cxx @@ -12,7 +12,7 @@ Function::Function(uint64_t start_address, bool dynamic, InformationManager* man void Function::setName(const std::string& new_name) { name = new_name; - RenameFunctionEvent event(new_name, start_address); + RenameFunctionEvent event(new_name, this, start_address); manager->dispatch(&event); } @@ -20,6 +20,7 @@ void Function::serialize(QXmlStreamWriter& stream) { stream.writeStartElement("function"); stream.writeAttribute("name", getName().c_str()); stream.writeAttribute("entry", QString::number(getStartAddress(), 16)); + stream.writeAttribute("dynamic", dynamic? "yes" : "no"); for (auto& blockentry : blocks()) { blockentry.second->serialize(stream); @@ -32,6 +33,7 @@ Function* Function::deserialize(QXmlStreamReader& stream, InformationManager* ma Q_ASSERT(stream.name() == "function"); QString name = stream.attributes().value("name").toString(); + bool dynamic = stream.attributes().value("dynamic").toString() == "yes"; uint64_t entry = stream.attributes().value("entry").toULongLong(NULL, 16); Function* fun = manager->newFunction(entry); @@ -51,6 +53,7 @@ Function* Function::deserialize(QXmlStreamReader& stream, InformationManager* ma } fun->name = name.toStdString(); + fun->dynamic = dynamic; manager->finishFunction(fun); return fun;