mirror of
https://github.com/nextcloud/desktop.git
synced 2025-10-26 11:17:43 +00:00
Use climits for ULONG_MAX rather than modern C++ option
This commit is contained in:
parent
d1c1a18226
commit
32fea6523f
@ -29,6 +29,8 @@
|
||||
|
||||
#include "ui_protocolwidget.h"
|
||||
|
||||
#include <climits>
|
||||
|
||||
namespace Mirall {
|
||||
|
||||
ProtocolWidget::ProtocolWidget(QWidget *parent) :
|
||||
@ -262,7 +264,7 @@ void ProtocolWidget::computeResyncButtonEnabled()
|
||||
|
||||
void ProtocolWidget::slotProgressInfo( const QString& folder, const Progress::Info& progress )
|
||||
{
|
||||
if( progress._completedFileCount == std::numeric_limits<quint64>::max() ) {
|
||||
if( progress._completedFileCount == ULLONG_MAX ) {
|
||||
// The sync is restarting, clean the old items
|
||||
cleanIgnoreItems(folder);
|
||||
computeResyncButtonEnabled();
|
||||
|
||||
@ -29,6 +29,7 @@
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include <climits>
|
||||
#include <assert.h>
|
||||
|
||||
#include <QDebug>
|
||||
@ -656,7 +657,7 @@ void SyncEngine::slotDiscoveryJobFinished(int discoveryResult)
|
||||
|
||||
// To announce the beginning of the sync
|
||||
emit aboutToPropagate(_syncedItems);
|
||||
_progressInfo._completedFileCount = std::numeric_limits<quint64>::max(); // indicate the start with max
|
||||
_progressInfo._completedFileCount = ULLONG_MAX; // indicate the start with max
|
||||
emit transmissionProgress(_progressInfo);
|
||||
_progressInfo._completedFileCount = 0;
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user