Propagator: Fix compilation

It is still protected on Qt4
This commit is contained in:
Markus Goetz 2014-02-10 15:46:09 +01:00
parent 104cf680a6
commit 8c9a65635f

View file

@ -354,7 +354,11 @@ void PropagateUploadFile::start()
if( state == HBF_SOURCE_FILE_CHANGE ) {
if( attempts++ < 5 ) { /* FIXME: How often do we want to try? */
qDebug("SOURCE file has changed during upload, retry #%d in %d seconds!", attempts, 2*attempts);
#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
QThread::sleep(2*attempts);
#else
sleep(2*attempts);
#endif
if( _previousFileSize == 0 ) {
_previousFileSize = _item._size;
} else {
@ -402,7 +406,11 @@ void PropagateUploadFile::start()
if( attempts++ < 5 ) { /* FIXME: How often do we want to try? */
qDebug("SOURCE file has changed after upload, retry #%d in %d seconds!", attempts, 2*attempts);
#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
QThread::sleep(2*attempts);
#else
sleep(2*attempts);
#endif
continue;
}