From 3f73527fa1d34f68f82c82e4444de7a6e7d19695 Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Fri, 28 Apr 2017 14:23:51 +0300 Subject: service: fix compiler warnings & code style --- um/service/src/device.cpp | 2 +- um/wrappers/simple/src/device.cpp | 2 +- um/wrappers/simple/utils/exchange_ints.cpp | 2 +- um/wrappers/special/nt_path_converter/src/device.cpp | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) (limited to 'um') diff --git a/um/service/src/device.cpp b/um/service/src/device.cpp index 5643106..1bdb42f 100644 --- a/um/service/src/device.cpp +++ b/um/service/src/device.cpp @@ -129,7 +129,7 @@ namespace std template <> void swap( libservice::Device& a, - libservice::Device& b) + libservice::Device& b) LIBSERVICE_NOEXCEPT { a.swap(b); } diff --git a/um/wrappers/simple/src/device.cpp b/um/wrappers/simple/src/device.cpp index 57e6963..2d49ff3 100644 --- a/um/wrappers/simple/src/device.cpp +++ b/um/wrappers/simple/src/device.cpp @@ -13,7 +13,7 @@ namespace libsimple { namespace { - const char* const device_path = "\\\\.\\simple_device1"; + const auto device_path = "\\\\.\\simple_device1"; const auto exchange_ints_ctl_code = CTL_CODE(0x8001, 0x800, METHOD_BUFFERED, FILE_ANY_ACCESS); } diff --git a/um/wrappers/simple/utils/exchange_ints.cpp b/um/wrappers/simple/utils/exchange_ints.cpp index 2935b2f..0b06ad6 100644 --- a/um/wrappers/simple/utils/exchange_ints.cpp +++ b/um/wrappers/simple/utils/exchange_ints.cpp @@ -24,7 +24,7 @@ int main(int argc, char* argv[]) { try { - unsigned int src; + unsigned int src = 0; if (argc != 2 || !parse_int(src, argv[1])) { diff --git a/um/wrappers/special/nt_path_converter/src/device.cpp b/um/wrappers/special/nt_path_converter/src/device.cpp index 90cd12f..2b5b89a 100644 --- a/um/wrappers/special/nt_path_converter/src/device.cpp +++ b/um/wrappers/special/nt_path_converter/src/device.cpp @@ -16,7 +16,7 @@ namespace libnt_path_converter { namespace { - const char* const device_path = "\\\\.\\nt_path_converter"; + const auto device_path = "\\\\.\\nt_path_converter"; const auto control_code = CTL_CODE(0x8000, 0x800, METHOD_BUFFERED, FILE_ANY_ACCESS); } -- cgit v1.2.3