From c0642fe993e8d43b063f77354dfddab289bbac5e Mon Sep 17 00:00:00 2001 From: Celtic Minstrel Date: Mon, 29 Dec 2014 15:13:52 -0500 Subject: [PATCH] Fix Mac build --- src/tools/cursors.mac.mm | 4 ++-- src/tools/tarball.hpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/tools/cursors.mac.mm b/src/tools/cursors.mac.mm index 816b0112..5d6cd8f9 100644 --- a/src/tools/cursors.mac.mm +++ b/src/tools/cursors.mac.mm @@ -57,9 +57,9 @@ static NSImage* imageFromURL(CFURLRef url){ return newImage; } -Cursor::Cursor(const char* path, float hotSpotX, float hotSpotY){ +Cursor::Cursor(std::string path, float hotSpotX, float hotSpotY){ FSRef ref; - FSPathMakeRef((UInt8*)path, &ref, NULL); + FSPathMakeRef((UInt8*)path.c_str(), &ref, NULL); CFURLRef imgPath = CFURLCreateFromFSRef(NULL, &ref); NSImage *img = imageFromURL(imgPath); diff --git a/src/tools/tarball.hpp b/src/tools/tarball.hpp index f0c31c11..12154187 100644 --- a/src/tools/tarball.hpp +++ b/src/tools/tarball.hpp @@ -39,7 +39,7 @@ class tarball { // This seems to be necessary to compile in Visual Studio // Seemingly, stringstream is non-copyable. tarfile() {} - tarfile(tarfile& other) { + tarfile(const tarfile& other) { contents.str(""); contents << other.contents.str(); }