diff options
author | Shane Kerr <shane@isc.org> | 2012-12-21 10:11:05 +0100 |
---|---|---|
committer | Shane Kerr <shane@isc.org> | 2013-01-14 16:54:58 +0100 |
commit | 6b6cbde6a1ac6ad0f3f11923ee6633ced00d529b (patch) | |
tree | 2c9b54233db4d3f3778051b682dc2488bce07451 /tests/tools | |
parent | Merge branch 'master' into trac2507 (diff) | |
download | kea-6b6cbde6a1ac6ad0f3f11923ee6633ced00d529b.tar.xz kea-6b6cbde6a1ac6ad0f3f11923ee6633ced00d529b.zip |
[2571] Change from char to int when we need special character values.
In cases where we use values outside of normal character range (-128
to 127 or 0 to 255) to indicate special things, like EOF, we need to
insure that we can hold these values. To do that, we use an int.
It turns out that the default type conversions also meant that our
JSON conversion from strings would break in some cases. A test was
added to show that, and to confirm the fix.
Diffstat (limited to 'tests/tools')
-rw-r--r-- | tests/tools/perfdhcp/command_options.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/tools/perfdhcp/command_options.cc b/tests/tools/perfdhcp/command_options.cc index 9de07ca1eb..f770373f6e 100644 --- a/tests/tools/perfdhcp/command_options.cc +++ b/tests/tools/perfdhcp/command_options.cc @@ -134,7 +134,7 @@ CommandOptions::parse(int argc, char** const argv) { bool CommandOptions::initialize(int argc, char** argv) { - char opt = 0; // Subsequent options returned by getopt() + int opt = 0; // Subsequent options returned by getopt() std::string drop_arg; // Value of -D<value>argument size_t percent_loc = 0; // Location of % sign in -D<value> double drop_percent = 0; // % value (1..100) in -D<value%> |