mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
lib/card: pass string as const reference to lookupIp()
This commit is contained in:
parent
95e29f2706
commit
c3382b9e18
2 changed files with 3 additions and 2 deletions
|
@ -75,7 +75,7 @@ public:
|
|||
bool reset() { return true; }
|
||||
void dump() { }
|
||||
|
||||
ip::IpCore* lookupIp(std::string name) const;
|
||||
ip::IpCore* lookupIp(const std::string& name) const;
|
||||
|
||||
ip::IpCoreList ips; ///< IPs located on this FPGA card
|
||||
|
||||
|
|
|
@ -132,7 +132,8 @@ fpga::PCIeCardFactory::create()
|
|||
|
||||
|
||||
ip::IpCore*
|
||||
PCIeCard::lookupIp(std::string name) const {
|
||||
PCIeCard::lookupIp(const std::string& name) const
|
||||
{
|
||||
for(auto& ip : ips) {
|
||||
if(*ip == name) {
|
||||
return ip.get();
|
||||
|
|
Loading…
Add table
Reference in a new issue