mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-30 22:20:21 +00:00
Uemis downloader: clean up the path for Windows mount point
Oops, we left the (UEMISSDA) in the path. This can never have worked without the user manually correcting it to just show the drive letter. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
f647e3cf1e
commit
5810aedeac
1 changed files with 11 additions and 1 deletions
|
@ -305,10 +305,20 @@ void DownloadFromDCWidget::on_downloadCancelRetryButton_clicked()
|
|||
thread->deleteLater();
|
||||
}
|
||||
|
||||
data.devname = strdup(ui.device->currentText().toUtf8().data());
|
||||
data.vendor = strdup(ui.vendor->currentText().toUtf8().data());
|
||||
data.product = strdup(ui.product->currentText().toUtf8().data());
|
||||
if (same_string(data.vendor, "Uemis")) {
|
||||
char *colon;
|
||||
char *devname = strdup(ui.device->currentText().toUtf8().data());
|
||||
|
||||
if ((colon = strstr(devname, ":\\ (UEMISSDA)")) != NULL) {
|
||||
*(colon + 2) = '\0';
|
||||
fprintf(stderr, "shortened devname to \"%s\"", data.devname);
|
||||
}
|
||||
data.devname = devname;
|
||||
} else {
|
||||
data.devname = strdup(ui.device->currentText().toUtf8().data());
|
||||
}
|
||||
data.descriptor = descriptorLookup[ui.vendor->currentText() + ui.product->currentText()];
|
||||
data.force_download = ui.forceDownload->isChecked();
|
||||
data.create_new_trip = ui.createNewTrip->isChecked();
|
||||
|
|
Loading…
Reference in a new issue