Skip to content

Commit

Permalink
Windows hotfix
Browse files Browse the repository at this point in the history
  • Loading branch information
geneotech committed May 2, 2023
1 parent 0a85c33 commit 1a3edaf
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/augs/audio/sound_data.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,11 @@ namespace augs {
std::memcpy(samples.data(), buffer.data(), buffer.size());
}
else if (extension == ".wav") {
#if PLATFORM_UNIX
auto wav_file = fclosed_unique(fopen(path_str.c_str(), "rbe"));
#else
auto wav_file = fclosed_unique(fopen(path_str.c_str(), "rb"));
#endif

if (!wav_file) {
throw sound_decoding_error("Failed to decode %x: could not open the file for reading.", path);
Expand Down

0 comments on commit 1a3edaf

Please sign in to comment.