diff options
author | Robin Gareus <robin@gareus.org> | 2019-11-21 17:48:56 +0100 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2019-11-21 17:48:56 +0100 |
commit | d4ecfc7d8577e278bd4db3564fc418a780c5af79 (patch) | |
tree | b9ae5f3737ba3826f991134ede16f7b2b76977e0 /libs/ardour/session_state.cc | |
parent | 216492c60c30860d973de132462cb05bab755b34 (diff) |
Use new boost::optional API
get_value_or() has been deprecated since boost 1.56
Diffstat (limited to 'libs/ardour/session_state.cc')
-rw-r--r-- | libs/ardour/session_state.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libs/ardour/session_state.cc b/libs/ardour/session_state.cc index 51a057abf2..5222c85a8e 100644 --- a/libs/ardour/session_state.cc +++ b/libs/ardour/session_state.cc @@ -961,7 +961,7 @@ Session::load_state (string snapshot_name) /* there is pending state from a crashed capture attempt */ boost::optional<int> r = AskAboutPendingState(); - if (r.get_value_or (1)) { + if (r.value_or (1)) { state_was_pending = true; } } @@ -1540,7 +1540,7 @@ Session::set_state (const XMLNode& node, int version) assert (AudioEngine::instance()->running ()); if (_base_sample_rate != AudioEngine::instance()->sample_rate ()) { boost::optional<int> r = AskAboutSampleRateMismatch (_base_sample_rate, _current_sample_rate); - if (r.get_value_or (0)) { + if (r.value_or (0)) { goto out; } } @@ -2376,7 +2376,7 @@ retry: } if (!no_questions_about_missing_files) { - user_choice = MissingFile (this, err.path, err.type).get_value_or (-1); + user_choice = MissingFile (this, err.path, err.type).value_or (-1); } else { user_choice = -2; } @@ -3217,7 +3217,7 @@ int Session::ask_about_playlist_deletion (boost::shared_ptr<Playlist> p) { boost::optional<int> r = AskAboutPlaylistDeletion (p); - return r.get_value_or (1); + return r.value_or (1); } void |