Skip to content

Commit

Permalink
Merged revision(s) 20367 from branches/OpenMPT-1.30:
Browse files Browse the repository at this point in the history
Merged revision(s) 20366 from branches/OpenMPT-1.31/libopenmpt/xmp-openmpt:
Merged revision(s) 20365 from trunk/OpenMPT:
[Fix] xmp-openmpt: Fix xmplay_streambuf::underflow(). When returning eof, we also need to set the get area to empty according to the standard.
........
........
........


git-svn-id: https://source.openmpt.org/svn/openmpt/branches/OpenMPT-1.28@20369 56274372-70c3-4bfc-bfc3-4c3a0b034d27
  • Loading branch information
manxorist committed Mar 15, 2024
1 parent 9c06ce2 commit 8e855ee
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libopenmpt/xmp-openmpt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -510,10 +510,10 @@ std::streambuf::int_type xmplay_streambuf::underflow() {
start += put_back_count;
}
std::size_t n = xmpffile->Read( file, start, buffer.size() - ( start - base ) );
setg( base, start, start + n );
if ( n == 0 ) {
return traits_type::eof();
}
setg( base, start, start + n );
return traits_type::to_int_type( *gptr() );
}

Expand Down

0 comments on commit 8e855ee

Please sign in to comment.