Explorar o código

Fix invalid implicit conversion from wxString to std::string

This fails to compile because CreateTempFileName returns a wxString
which doesn't have an implicit conversion to std::string. One solution
would be to call ToStdString() to get a std::string, but this change
just uses auto to deduce the type.
Jonathan Wakely %!s(int64=4) %!d(string=hai) anos
pai
achega
a297cc572a
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      lib/SCSI2SD/src/scsi2sd-util6/scsi2sd-util.cc

+ 1 - 1
lib/SCSI2SD/src/scsi2sd-util6/scsi2sd-util.cc

@@ -562,7 +562,7 @@ private:
 		}
 #endif
 
-		std::string tmpFile =
+		auto tmpFile =
 			wxFileName::CreateTempFileName(
 				_("SCSI2SD_MARKER"), static_cast<wxFile*>(NULL));
 		wxRemoveFile(tmpFile); // dfu-util won't overwrite.