diff options
-rwxr-xr-x | configure.py | 2 | ||||
-rw-r--r-- | src/lib/mac/poly1305/poly1305.cpp | 2 | ||||
-rw-r--r-- | src/lib/math/bigint/bigint.h | 2 | ||||
-rw-r--r-- | src/lib/utils/types.h | 36 | ||||
-rwxr-xr-x | src/scripts/install.py | 2 | ||||
-rw-r--r-- | src/tests/test_bigint.cpp | 4 |
6 files changed, 19 insertions, 29 deletions
diff --git a/configure.py b/configure.py index b04793877..b8fb3185f 100755 --- a/configure.py +++ b/configure.py @@ -1250,7 +1250,7 @@ def create_template_vars(build_config, options, modules, cc, arch, osinfo): 'scripts_dir': os.path.join(build_config.src_dir, 'scripts'), - 'with_shared_lib': options.build_shared_lib, + 'build_shared_lib': options.build_shared_lib, 'appobj_dir': build_config.appobj_dir, 'libobj_dir': build_config.libobj_dir, diff --git a/src/lib/mac/poly1305/poly1305.cpp b/src/lib/mac/poly1305/poly1305.cpp index 506150b0f..659667baf 100644 --- a/src/lib/mac/poly1305/poly1305.cpp +++ b/src/lib/mac/poly1305/poly1305.cpp @@ -190,7 +190,7 @@ void Poly1305::final_result(byte out[]) if(m_buf_pos != 0) { m_buf[m_buf_pos] = 1; - const auto len = m_buf.size() - m_buf_pos - 1; + const size_t len = m_buf.size() - m_buf_pos - 1; if (len > 0) { clear_mem(&m_buf[m_buf_pos+1], len); diff --git a/src/lib/math/bigint/bigint.h b/src/lib/math/bigint/bigint.h index fed986882..4a37425f5 100644 --- a/src/lib/math/bigint/bigint.h +++ b/src/lib/math/bigint/bigint.h @@ -278,7 +278,7 @@ class BOTAN_DLL BigInt if(top_word < size()) { - const auto len = size() - (top_word + 1); + const size_t len = size() - (top_word + 1); if (len > 0) { clear_mem(&m_reg[top_word+1], len); diff --git a/src/lib/utils/types.h b/src/lib/utils/types.h index d1de9e2a6..f5754983d 100644 --- a/src/lib/utils/types.h +++ b/src/lib/utils/types.h @@ -1,6 +1,7 @@ /* * Low Level Types * (C) 1999-2007 Jack Lloyd +* (C) 2015 Simon Warta (Kullo GmbH) * * Botan is released under the Simplified BSD License (see license.txt) */ @@ -11,7 +12,7 @@ #include <botan/build.h> #include <botan/assert.h> #include <cstddef> -#include <stdint.h> +#include <cstdint> #include <memory> /** @@ -19,21 +20,19 @@ */ namespace Botan { -using ::uint8_t; -using ::uint16_t; -using ::uint32_t; -using ::uint64_t; -using ::int32_t; -using ::int64_t; +using std::uint8_t; +using std::uint16_t; +using std::uint32_t; +using std::uint64_t; +using std::int32_t; +using std::int64_t; +using std::size_t; -using ::size_t; - -typedef uint8_t byte; -typedef uint16_t u16bit; -typedef uint32_t u32bit; -typedef uint64_t u64bit; - -typedef int32_t s32bit; +using byte = std::uint8_t; +using u16bit = std::uint16_t; +using u32bit = std::uint32_t; +using u64bit = std::uint64_t; +using s32bit = std::int32_t; /** * A default buffer size; typically a memory page @@ -42,11 +41,4 @@ static const size_t DEFAULT_BUFFERSIZE = BOTAN_DEFAULT_BUFFER_SIZE; } -namespace Botan_types { - -using Botan::byte; -using Botan::u32bit; - -} - #endif diff --git a/src/scripts/install.py b/src/scripts/install.py index b25ec42de..b91e68b02 100755 --- a/src/scripts/install.py +++ b/src/scripts/install.py @@ -146,7 +146,7 @@ def main(args = None): copy_file(os.path.join(out_dir, static_lib), os.path.join(lib_dir, os.path.basename(static_lib))) - if bool(cfg['with_shared_lib']): + if bool(cfg['build_shared_lib']): if str(cfg['os']) == "windows": shared_lib = process_template('%{lib_prefix}%{libname}.%{so_suffix}') # botan.dll copy_executable(os.path.join(out_dir, shared_lib), diff --git a/src/tests/test_bigint.cpp b/src/tests/test_bigint.cpp index 82fc49861..3cf403743 100644 --- a/src/tests/test_bigint.cpp +++ b/src/tests/test_bigint.cpp @@ -342,9 +342,7 @@ size_t test_bigint() std::vector<std::string> substr = parse(line); -#if DEBUG - std::cout << "Testing: " << algorithm << std::endl; -#endif + // std::cout << "Testing: " << algorithm << std::endl; size_t new_errors = 0; if(algorithm.find("Addition") != std::string::npos) |