From: Vadim Zeitlin Date: Tue, 8 Mar 2005 20:16:44 +0000 (+0000) Subject: return name and extension by const ref, not by value, to prevent bugs as the one... X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/6a168c177c0572f32f98e8a9d8ba9adcd1c2d968 return name and extension by const ref, not by value, to prevent bugs as the one just fixed by patch 1159289 from compiling git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32683 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/include/wx/msw/gdiimage.h b/include/wx/msw/gdiimage.h index 97d81bbd9f..a58afe00fc 100644 --- a/include/wx/msw/gdiimage.h +++ b/include/wx/msw/gdiimage.h @@ -102,8 +102,8 @@ public: void SetExtension(const wxString& ext) { m_extension = ext; } void SetType(long type) { m_type = type; } - wxString GetName() const { return m_name; } - wxString GetExtension() const { return m_extension; } + const wxString& GetName() const { return m_name; } + const wxString& GetExtension() const { return m_extension; } long GetType() const { return m_type; } // real handler operations: to implement in derived classes