Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some issues with large files #3293

Merged
merged 3 commits into from
Feb 9, 2017
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 14 additions & 6 deletions src/core/SampleBuffer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
*
*/


#include "SampleBuffer.h"


Expand Down Expand Up @@ -58,6 +57,7 @@
#include "DrumSynth.h"
#include "endian_handling.h"
#include "Engine.h"
#include "GuiApplication.h"
#include "interpolation.h"
#include "Mixer.h"
#include "templates.h"
Expand Down Expand Up @@ -223,7 +223,7 @@ void SampleBuffer::update( bool _keep_settings )
}
}

if( ! fileLoadError )
if( !fileLoadError )
{
#ifdef LMMS_HAVE_OGGVORBIS
// workaround for a bug in libsndfile or our libsndfile decoder
Expand Down Expand Up @@ -291,11 +291,19 @@ void SampleBuffer::update( bool _keep_settings )

if( fileLoadError )
{
QMessageBox::information( NULL,
"Fail to open file",
"Audio files are limited to 100 MB "
"in size and 1 hour of playing time",
QString message = "Audio files are limited to 100 MB "
"in size and 1 hour of playing time";
if( gui )
{
QMessageBox::information( NULL,
"Fail to open file", message,
QMessageBox::Ok );
}
else
{
fprintf( stderr, "%s\n", message.toUtf8().constData() );
exit( EXIT_FAILURE );
PhysSong marked this conversation as resolved.
Show resolved Hide resolved
}
}
}

Expand Down