Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 60ecb440 authored by Wolfgang Bauer's avatar Wolfgang Bauer

Reactivate commented out code in DataSourceFactory::checkLocalFile()

This code is needed because it creates the (empty) destination file.
Without it, KIO::open() in DataSourceFactory::start() will always fail,
and the downloads never start.

In particular, the multisegmentkio plugin works again now.
parent 237463ce
......@@ -161,13 +161,13 @@ void DataSourceFactory::slotFinishedDownload(TransferDataSource *source, KIO::fi
m_speedTimer->stop();
m_finished = true;
}
//FIXME is this even needed
bool DataSourceFactory::checkLocalFile()
{
QString dest_orig = m_dest.toLocalFile();
QString _dest_part(dest_orig);
/*KDE_struct_stat buff_part;
KDE_struct_stat buff_part;
bool bPartExists = (KDE::stat( _dest_part, &buff_part ) != -1);
if(!bPartExists)
{
......@@ -185,7 +185,7 @@ bool DataSourceFactory::checkLocalFile()
{
close(fd);
}
}*///TODO: Port if needed
}//TODO: Port to use Qt functions maybe
qCDebug(KGET_DEBUG) << "success";
return true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment