diff options
author | bunnei <bunneidev@gmail.com> | 2014-08-18 15:35:47 -0400 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2014-08-18 15:35:47 -0400 |
commit | 0a1aab5b4259b555e77554376d87cc641c4fe922 (patch) | |
tree | 209400d4a1f7652a127cb40e167c71cc8f755fc1 | |
parent | 3bdf052e75f97d98b4ed76c73b782cb391f06c40 (diff) | |
parent | a49a5fa4d94e48e1f049365a8071ab5207ac5eee (diff) |
Merge pull request #57 from lioncash/str
Common: Don't return a reference to a string when calling GetName in symbols.cpp
-rw-r--r-- | src/common/symbols.cpp | 2 | ||||
-rw-r--r-- | src/common/symbols.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/common/symbols.cpp b/src/common/symbols.cpp index dcc9eeac5..d61f4c0c6 100644 --- a/src/common/symbols.cpp +++ b/src/common/symbols.cpp @@ -40,7 +40,7 @@ namespace Symbols return symbol; } - const std::string& GetName(u32 _address) + const std::string GetName(u32 _address) { return GetSymbol(_address).name; } diff --git a/src/common/symbols.h b/src/common/symbols.h index b76749654..e59bc5dd4 100644 --- a/src/common/symbols.h +++ b/src/common/symbols.h @@ -32,7 +32,7 @@ namespace Symbols void Add(u32 _address, const std::string& _name, u32 _size, u32 _type); TSymbol GetSymbol(u32 _address); - const std::string& GetName(u32 _address); + const std::string GetName(u32 _address); void Remove(u32 _address); void Clear(); }; |