diff --git a/src/drivers/Qt/ConsoleViewerGL.cpp b/src/drivers/Qt/ConsoleViewerGL.cpp index 28383b40..dc0ed2c3 100644 --- a/src/drivers/Qt/ConsoleViewerGL.cpp +++ b/src/drivers/Qt/ConsoleViewerGL.cpp @@ -218,7 +218,7 @@ void ConsoleViewGL_t::transfer2LocalBuffer(void) { int i=0, hq = 0; int numPixels = nes_shm->video.ncol * nes_shm->video.nrow; - int cpSize = numPixels * 4; + unsigned int cpSize = numPixels * 4; uint8_t *src, *dest; if ( cpSize > localBufSize ) diff --git a/src/drivers/Qt/ConsoleViewerSDL.cpp b/src/drivers/Qt/ConsoleViewerSDL.cpp index a345fb37..07327d14 100644 --- a/src/drivers/Qt/ConsoleViewerSDL.cpp +++ b/src/drivers/Qt/ConsoleViewerSDL.cpp @@ -135,7 +135,7 @@ void ConsoleViewSDL_t::transfer2LocalBuffer(void) { int i=0, hq = 0; int numPixels = nes_shm->video.ncol * nes_shm->video.nrow; - int cpSize = numPixels * 4; + unsigned int cpSize = numPixels * 4; uint8_t *src, *dest; if ( cpSize > localBufSize )