Ask for user confirmation because proceeding with recursive torrent download (security risk)

Fix "add file" dialog in torrent creation tool
This commit is contained in:
Christophe Dumez
2010-03-20 11:30:11 +00:00
parent 73c312ec1a
commit 530fbfc9b4
5 changed files with 45 additions and 12 deletions

View File

@@ -85,7 +85,7 @@ void createtorrent::on_addFolder_button_clicked(){
}
void createtorrent::on_addFile_button_clicked(){
QString file = QFileDialog::getOpenFileName(this, tr("Select a file to add to the torrent"), QDir::homePath(), QString(), 0, QFileDialog::ShowDirsOnly);
QString file = QFileDialog::getOpenFileName(this, tr("Select a file to add to the torrent"), QDir::homePath());
if(!file.isEmpty())
textInputPath->setText(file);
}