Use reference instead of copy.
This commit is contained in:
parent
de795b766a
commit
1d7aa7a2f5
@ -265,9 +265,8 @@ std::vector<std::string> Steam::getFriends()
|
|||||||
* filename. Note that the avatar is always saved in png format (independent
|
* filename. Note that the avatar is always saved in png format (independent
|
||||||
* on what is specified as filename).
|
* on what is specified as filename).
|
||||||
*/
|
*/
|
||||||
int Steam::saveAvatarAs(const std::string filename)
|
int Steam::saveAvatarAs(const std::string &filename)
|
||||||
{
|
{
|
||||||
//std::string s = sendCommand(std::string("avatar ")+filename);
|
|
||||||
std::string s = sendCommand("avatar");
|
std::string s = sendCommand("avatar");
|
||||||
if(s=="filename")
|
if(s=="filename")
|
||||||
s=sendCommand(filename);
|
s=sendCommand(filename);
|
||||||
|
@ -61,7 +61,7 @@ public:
|
|||||||
~Steam();
|
~Steam();
|
||||||
const std::string& getUserName();
|
const std::string& getUserName();
|
||||||
const std::string& getSteamID();
|
const std::string& getSteamID();
|
||||||
int saveAvatarAs(const std::string filename);
|
int saveAvatarAs(const std::string &filename);
|
||||||
std::vector<std::string> getFriends();
|
std::vector<std::string> getFriends();
|
||||||
// ------------------------------------------------------------------------
|
// ------------------------------------------------------------------------
|
||||||
/** Returns true if the connection to the Steam API was successful, i.e.
|
/** Returns true if the connection to the Steam API was successful, i.e.
|
||||||
|
Loading…
Reference in New Issue
Block a user