GUI-Qt: Avoid divide by zero on empty gamelist folder.

This commit is contained in:
refractionpcsx2 committed 2022-07-18 08:47:57 +01:00
1 parent 395f4e904c
commit 55db243362
1 file changed
+1 -1
+1 -1
View File
@@ -822,7 +822,7 @@ void MainWindow::updateWindowState(bool force_visible)
void MainWindow::setProgressBar(int current, int total)
{
const int value = (current * 100) / total;
const int value = (total != 0) ? ((current * 100) / total) : 0;
if (m_status_progress_widget->value() != value)
m_status_progress_widget->setValue(value);