TileCache: avoid copying these for each invocation
Change-Id: Icaf84699d7f54f2f977162a040aed1f4090f680d
This commit is contained in:
parent
9e64efe78b
commit
0833a99b37
2 changed files with 4 additions and 4 deletions
|
@ -44,7 +44,7 @@ using Poco::URI;
|
|||
|
||||
using namespace LOOLProtocol;
|
||||
|
||||
void TileBeingRendered::subscribe(std::weak_ptr<MasterProcessSession> session)
|
||||
void TileBeingRendered::subscribe(const std::weak_ptr<MasterProcessSession>& session)
|
||||
{
|
||||
_subscribers.push_back(session);
|
||||
}
|
||||
|
@ -382,7 +382,7 @@ void TileCache::invalidateTiles(const std::string& tiles)
|
|||
}
|
||||
}
|
||||
|
||||
void TileCache::removeFile(const std::string fileName)
|
||||
void TileCache::removeFile(const std::string& fileName)
|
||||
{
|
||||
Log::warn("Removing tile: " + fileName);
|
||||
Util::removeFile(_persCacheDir + "/" + fileName);
|
||||
|
|
|
@ -35,7 +35,7 @@ class TileBeingRendered
|
|||
std::vector<std::weak_ptr<MasterProcessSession>> _subscribers;
|
||||
|
||||
public:
|
||||
void subscribe(std::weak_ptr<MasterProcessSession> session);
|
||||
void subscribe(const std::weak_ptr<MasterProcessSession>& session);
|
||||
std::vector<std::weak_ptr<MasterProcessSession>> getSubscribers();
|
||||
};
|
||||
|
||||
|
@ -84,7 +84,7 @@ public:
|
|||
void invalidateTiles(int part, int x, int y, int width, int height);
|
||||
|
||||
// Removes the given file from both editing and persistent cache
|
||||
void removeFile(const std::string fileName);
|
||||
void removeFile(const std::string& fileName);
|
||||
|
||||
private:
|
||||
/// Path of the (sub-)cache dir, the parameter specifies which (sub-)cache to use.
|
||||
|
|
Loading…
Reference in a new issue