diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2015-05-21 13:45:25 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-05-21 13:45:25 -0700 |
commit | 00b1469658fc43ec6448cd01e59405bfeeef40cb (patch) | |
tree | ecb8fa67098432c49e82c1fd0dcf76f32c3d4b82 /qt-ui/downloadfromdivecomputer.cpp | |
parent | 9ca033c55038efed82b8a09dcd84e310a58f2e73 (diff) | |
parent | 707a1f7af71b441f333bcf45fd980a176542aab3 (diff) | |
download | subsurface-00b1469658fc43ec6448cd01e59405bfeeef40cb.tar.gz |
Merge branch 'v4.4-branch' into newmaster
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/downloadfromdivecomputer.cpp')
-rw-r--r-- | qt-ui/downloadfromdivecomputer.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/qt-ui/downloadfromdivecomputer.cpp b/qt-ui/downloadfromdivecomputer.cpp index 5f0487e8c..e6b51a513 100644 --- a/qt-ui/downloadfromdivecomputer.cpp +++ b/qt-ui/downloadfromdivecomputer.cpp @@ -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(); |