Skip to content

Commit

Permalink
LibAudio: Use handle_any_error in WAV loader
Browse files Browse the repository at this point in the history
It was using has_any_error, which causes an assertion failure when
destroying the stream. Instead, use handle_any_error, as the
WAV loader does handle errors.
  • Loading branch information
Lubrsi authored and awesomekling committed Mar 1, 2021
1 parent a66f96f commit 69df86c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Userland/Libraries/LibAudio/WavLoader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ bool WavLoaderPlugin::parse_header()
ok = false;
} else {
*m_stream >> value;
if (m_stream->has_any_error())
if (m_stream->handle_any_error())
ok = false;
}
return value;
Expand All @@ -139,7 +139,7 @@ bool WavLoaderPlugin::parse_header()
ok = false;
} else {
*m_stream >> value;
if (m_stream->has_any_error())
if (m_stream->handle_any_error())
ok = false;
}
return value;
Expand All @@ -153,7 +153,7 @@ bool WavLoaderPlugin::parse_header()
ok = false;
} else {
*m_stream >> value;
if (m_stream->has_any_error())
if (m_stream->handle_any_error())
ok = false;
}
return value;
Expand Down

0 comments on commit 69df86c

Please sign in to comment.