summaryrefslogtreecommitdiffstats
path: root/cloud_print/virtual_driver
diff options
context:
space:
mode:
authorpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-18 01:40:47 +0000
committerpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-18 01:40:47 +0000
commit481c3e82e2dcbcb676501f18bc8f58900071b935 (patch)
treeb41b70589f0b082edffa7322b1c06af23c4b32bc /cloud_print/virtual_driver
parentcf85b9ad701b8363e3d1d54d54390dcdf4a45291 (diff)
downloadchromium_src-481c3e82e2dcbcb676501f18bc8f58900071b935.zip
chromium_src-481c3e82e2dcbcb676501f18bc8f58900071b935.tar.gz
chromium_src-481c3e82e2dcbcb676501f18bc8f58900071b935.tar.bz2
Fixes for re-enabling more MSVC level 4 warnings: misc edition #2
This contains fixes for the following sorts of issues: * Assignment inside conditional * Taking the address of a temporary * Octal escape sequence terminated by decimal number * Signedness mismatch * Possibly-uninitialized local variable This also contains a small number of cleanups to nearby code (e.g. no else after return). BUG=81439 TEST=none Review URL: https://codereview.chromium.org/382673002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@283967 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cloud_print/virtual_driver')
-rw-r--r--cloud_print/virtual_driver/win/install/setup.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/cloud_print/virtual_driver/win/install/setup.cc b/cloud_print/virtual_driver/win/install/setup.cc
index 8613f3a..0a0cfe4 100644
--- a/cloud_print/virtual_driver/win/install/setup.cc
+++ b/cloud_print/virtual_driver/win/install/setup.cc
@@ -210,6 +210,7 @@ UINT CALLBACK CabinetCallback(PVOID data,
}
void ReadyDriverDependencies(const base::FilePath& destination) {
+ base::FilePath destination_copy(destination);
if (base::win::GetVersion() >= base::win::VERSION_VISTA) {
// GetCorePrinterDrivers and GetPrinterDriverPackagePath only exist on
// Vista and later. Winspool.drv must be delayloaded so these calls don't
@@ -221,15 +222,14 @@ void ReadyDriverDependencies(const base::FilePath& destination) {
1, &driver);
GetPrinterDriverPackagePath(NULL, NULL, NULL, driver.szPackageID,
package_path, MAX_PATH, &size);
- SetupIterateCabinet(package_path, 0, &CabinetCallback,
- &base::FilePath(destination));
+ SetupIterateCabinet(package_path, 0, &CabinetCallback, &destination_copy);
} else {
// Driver files are in the sp3 cab.
base::FilePath package_path;
PathService::Get(base::DIR_WINDOWS, &package_path);
package_path = package_path.Append(L"Driver Cache\\i386\\sp3.cab");
SetupIterateCabinet(package_path.value().c_str(), 0, &CabinetCallback,
- &base::FilePath(destination));
+ &destination_copy);
// Copy the rest from the driver cache or system dir.
base::FilePath driver_cache_path;