Propagator: Use QBA for responseTimestamp instead of QString

This commit is contained in:
Markus Goetz 2015-03-09 15:52:52 +01:00
parent 8746914f3b
commit 31e4009737
4 changed files with 6 additions and 6 deletions

View file

@ -129,7 +129,7 @@ void SyncRunFileLog::logItem( const SyncFileItem& item )
if( item._direction == SyncFileItem::None ) {
return;
}
QString ts = item._responseTimeStamp;
QString ts = QString::fromAscii(item._responseTimeStamp);
if( ts.length() > 6 ) {
QRegExp rx("(\\d\\d:\\d\\d:\\d\\d)");
if( ts.contains(rx) ) {

View file

@ -167,7 +167,7 @@ void AbstractNetworkJob::slotFinished()
}
// get the Date timestamp from reply
_responseTimestamp = QString::fromAscii(_reply->rawHeader("Date"));
_responseTimestamp = _reply->rawHeader("Date");
_duration = _durationTimer.elapsed();
if (_followRedirects) {
@ -207,7 +207,7 @@ quint64 AbstractNetworkJob::duration()
return _duration;
}
QString AbstractNetworkJob::responseTimestamp()
QByteArray AbstractNetworkJob::responseTimestamp()
{
return _responseTimestamp;
}

View file

@ -70,7 +70,7 @@ public:
void setIgnoreCredentialFailure(bool ignore);
bool ignoreCredentialFailure() const { return _ignoreCredentialFailure; }
QString responseTimestamp();
QByteArray responseTimestamp();
quint64 duration();
public slots:
@ -94,7 +94,7 @@ protected:
int maxRedirects() const { return 10; }
virtual bool finished() = 0;
QString _responseTimestamp;
QByteArray _responseTimestamp;
QElapsedTimer _durationTimer;
quint64 _duration;
bool _timedout; // set to true when the timeout slot is recieved

View file

@ -140,7 +140,7 @@ public:
Status _status;
QString _errorString; // Contains a string only in case of error
int _httpErrorCode;
QString _responseTimeStamp;
QByteArray _responseTimeStamp;
quint64 _requestDuration;
bool _isRestoration; // The original operation was forbidden, and this is a restoration
int _affectedItems; // the number of affected items by the operation on this item.