thread/*Cond: rename methods to match std::condition_variable

This commit is contained in:
Max Kellermann
2019-04-25 18:33:09 +02:00
parent 5bc8cd0ecb
commit b51bae5500
25 changed files with 72 additions and 72 deletions

View File

@@ -127,7 +127,7 @@ DecoderBridge::FlushChunk() noexcept
const std::lock_guard<Mutex> protect(dc.mutex);
if (dc.client_is_waiting)
dc.client_cond.signal();
dc.client_cond.notify_one();
}
bool
@@ -310,7 +310,7 @@ DecoderBridge::CommandFinished() noexcept
}
dc.command = DecoderCommand::NONE;
dc.client_cond.signal();
dc.client_cond.notify_one();
}
SongTime

View File

@@ -67,7 +67,7 @@ DecoderControl::SetReady(const AudioFormat audio_format,
total_time = _duration;
state = DecoderState::DECODE;
client_cond.signal();
client_cond.notify_one();
}
bool

View File

@@ -199,7 +199,7 @@ public:
* calling this function.
*/
void Signal() noexcept {
cond.signal();
cond.notify_one();
}
/**
@@ -367,7 +367,7 @@ public:
assert(command != DecoderCommand::NONE);
command = DecoderCommand::NONE;
client_cond.signal();
client_cond.notify_one();
}
/**
@@ -428,11 +428,11 @@ private:
/* virtual methods from class InputStreamHandler */
void OnInputStreamReady() noexcept override {
cond.signal();
cond.notify_one();
}
void OnInputStreamAvailable() noexcept override {
cond.signal();
cond.notify_one();
}
};

View File

@@ -450,7 +450,7 @@ decoder_run_song(DecoderControl &dc,
throw FormatRuntimeError("Failed to decode %s", error_uri);
}
dc.client_cond.signal();
dc.client_cond.notify_one();
}
/**
@@ -479,7 +479,7 @@ try {
dc.state = DecoderState::ERROR;
dc.command = DecoderCommand::NONE;
dc.error = std::current_exception();
dc.client_cond.signal();
dc.client_cond.notify_one();
}
void