Allow local-scope strings to be passed in as constructor parameters.
git-svn-id: svn://localhost/ardour2/branches/3.0@7559 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
54d019cdd6
commit
66aeda8d8a
@ -135,13 +135,15 @@ class AudioEngine : public SessionHandlePtr
|
||||
|
||||
class PortRegistrationFailure : public std::exception {
|
||||
public:
|
||||
PortRegistrationFailure (const char* why = "") {
|
||||
reason = why;
|
||||
}
|
||||
virtual const char *what() const throw() { return reason; }
|
||||
PortRegistrationFailure (std::string const & why = "")
|
||||
: reason (why) {}
|
||||
|
||||
~PortRegistrationFailure () throw () {}
|
||||
|
||||
virtual const char *what() const throw () { return reason.c_str(); }
|
||||
|
||||
private:
|
||||
const char* reason;
|
||||
std::string reason;
|
||||
};
|
||||
|
||||
class NoBackendAvailable : public std::exception {
|
||||
|
Loading…
Reference in New Issue
Block a user