audio_in: fix compile errors with strict warnings enabled

Fixes #4373
This commit is contained in:
Christian Prochaska 2022-01-11 22:08:51 +01:00 committed by Christian Helmuth
parent 3ba316b015
commit 7b40ccea85
2 changed files with 8 additions and 8 deletions

View File

@ -182,7 +182,7 @@ class Audio_in::Stream
*
* \return position in stream queue
*/
unsigned packet_position(Packet *packet) { return packet - &_buf[0]; }
unsigned packet_position(Packet *packet) { return (unsigned)(packet - &_buf[0]); }
/**
* Check if stream queue is empty

View File

@ -32,8 +32,8 @@ class Audio_in::Session_rpc_object : public Genode::Rpc_object<Audio_in::Session
Genode::Attached_ram_dataspace _ds; /* contains Audio_in stream */
Genode::Signal_context_capability _data_cap;
Genode::Signal_context_capability _progress_cap;
Genode::Signal_context_capability _overrun_cap;
Genode::Signal_context_capability _progress_cap { };
Genode::Signal_context_capability _overrun_cap { };
bool _stopped; /* state */
@ -52,13 +52,13 @@ class Audio_in::Session_rpc_object : public Genode::Rpc_object<Audio_in::Session
** Signals **
**************/
void progress_sigh(Genode::Signal_context_capability sigh) {
void progress_sigh(Genode::Signal_context_capability sigh) override {
_progress_cap = sigh; }
void overrun_sigh(Genode::Signal_context_capability sigh) {
void overrun_sigh(Genode::Signal_context_capability sigh) override {
_overrun_cap = sigh; }
Genode::Signal_context_capability data_avail_sigh() {
Genode::Signal_context_capability data_avail_sigh() override {
return _data_cap; }
@ -66,8 +66,8 @@ class Audio_in::Session_rpc_object : public Genode::Rpc_object<Audio_in::Session
** Session interface **
***********************/
void start() { _stopped = false; }
void stop() { _stopped = true; }
void start() override { _stopped = false; }
void stop() override { _stopped = true; }
Genode::Dataspace_capability dataspace() { return _ds.cap(); }