From 5439a449f4937e36ea76b5451a070b36602d37bc Mon Sep 17 00:00:00 2001 From: Shawn Routhier Date: Wed, 10 Feb 2016 21:29:57 -0800 Subject: [PATCH] [trac4264] Fix some typos in the comments and docs --- doc/guide/classify.xml | 10 +++++----- src/lib/eval/eval.dox | 10 +++++----- src/lib/eval/eval_context.h | 4 ++-- src/lib/eval/lexer.ll | 2 +- src/lib/eval/parser.yy | 2 +- src/lib/eval/tests/context_unittest.cc | 2 +- src/lib/eval/tests/token_unittest.cc | 4 ++-- src/lib/eval/token.cc | 2 +- src/lib/eval/token.h | 10 +++++----- 9 files changed, 23 insertions(+), 23 deletions(-) diff --git a/doc/guide/classify.xml b/doc/guide/classify.xml index 5bbbb9f803..e261281637 100644 --- a/doc/guide/classify.xml +++ b/doc/guide/classify.xml @@ -189,11 +189,11 @@ sub-option with code "code" from the Relay Agent Information option - "relay[code].hex" attempts to extract value of the sub-option - "code" from the option inserted by the Relay Agent Information - (82) option. If the packet doesn't contain RAI option, or RAI - doesn't contain searched sub-option, the expression returns - empty string. The string is presented as a byte string of the + "relay[code].hex" attempts to extract the value of the sub-option + "code" from the option inserted as the Relay Agent Information + (82) option. If the packet doesn't contain a RAI option, or the RAI + option doesn't contain the requested sub-option, the expression returns + an empty string. The string is presented as a byte string of the option payload without the type code or length fields. This expression is allowed in DHCPv4 only. diff --git a/src/lib/eval/eval.dox b/src/lib/eval/eval.dox index b95b8ff03d..196068ead9 100644 --- a/src/lib/eval/eval.dox +++ b/src/lib/eval/eval.dox @@ -1,4 +1,4 @@ -// Copyright (C) 2015 Internet Systems Consortium, Inc. ("ISC") +// Copyright (C) 2015-2016 Internet Systems Consortium, Inc. ("ISC") // // This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this @@ -128,7 +128,7 @@ instantiated with the appropriate value and put onto the expression vector. @section dhcpEcalToken Supported tokens - There is a number of tokens implemented. Each token is derived from + There are a number of tokens implemented. Each token is derived from isc::eval::Token class and represents a certain expression primitive. Currently supported tokens are: @@ -137,10 +137,10 @@ instantiated with the appropriate value and put onto the expression vector. hex string, e.g. 0x666f6f which is actually "foo"; - isc::dhcp::TokenOption - represents an option in a packet, e.g. option[123].text; - - isc::dhcp::TokenEqual - represents equal (==) operator; - - isc::dhcp::TokenSubstring - represents substring(text, start, length) operator; + - isc::dhcp::TokenEqual - represents the equal (==) operator; + - isc::dhcp::TokenSubstring - represents the substring(text, start, length) operator; - isc::dhcp::TokenRelay4Option - represents a sub-option inserted by the - DHCPv4 relay, e.g. relay[123].text or relay[123].bin + DHCPv4 relay, e.g. relay[123].text or relay[123].hex More operators are expected to be implemented in upcoming releases. diff --git a/src/lib/eval/eval_context.h b/src/lib/eval/eval_context.h index 3007efc3d9..c5c0c20914 100644 --- a/src/lib/eval/eval_context.h +++ b/src/lib/eval/eval_context.h @@ -1,4 +1,4 @@ -// Copyright (C) 2015 Internet Systems Consortium, Inc. ("ISC") +// Copyright (C) 2015-2016 Internet Systems Consortium, Inc. ("ISC") // // This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this @@ -92,7 +92,7 @@ public: uint16_t convertOptionCode(const std::string& option_code, const isc::eval::location& loc); - /// @brief Option name convertion + /// @brief Option name conversion /// /// @param option_name the option name /// @param loc the location of the token diff --git a/src/lib/eval/lexer.ll b/src/lib/eval/lexer.ll index 3842b006b6..6af639b597 100644 --- a/src/lib/eval/lexer.ll +++ b/src/lib/eval/lexer.ll @@ -1,4 +1,4 @@ -/* Copyright (C) 2015 Internet Systems Consortium, Inc. ("ISC") +/* Copyright (C) 2015-2016 Internet Systems Consortium, Inc. ("ISC") This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this diff --git a/src/lib/eval/parser.yy b/src/lib/eval/parser.yy index 8716bc7bec..e44ae50445 100644 --- a/src/lib/eval/parser.yy +++ b/src/lib/eval/parser.yy @@ -1,4 +1,4 @@ -/* Copyright (C) 2015 Internet Systems Consortium, Inc. ("ISC") +/* Copyright (C) 2015-2016 Internet Systems Consortium, Inc. ("ISC") This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this diff --git a/src/lib/eval/tests/context_unittest.cc b/src/lib/eval/tests/context_unittest.cc index 4e3e8a8696..e93c4b2842 100644 --- a/src/lib/eval/tests/context_unittest.cc +++ b/src/lib/eval/tests/context_unittest.cc @@ -1,4 +1,4 @@ -// Copyright (C) 2015 Internet Systems Consortium, Inc. ("ISC") +// Copyright (C) 2015-2016 Internet Systems Consortium, Inc. ("ISC") // // This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this diff --git a/src/lib/eval/tests/token_unittest.cc b/src/lib/eval/tests/token_unittest.cc index 5778bc5b1c..9cd2897150 100644 --- a/src/lib/eval/tests/token_unittest.cc +++ b/src/lib/eval/tests/token_unittest.cc @@ -1,4 +1,4 @@ -// Copyright (C) 2015 Internet Systems Consortium, Inc. ("ISC") +// Copyright (C) 2015-2016 Internet Systems Consortium, Inc. ("ISC") // // This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this @@ -614,7 +614,7 @@ TEST_F(TokenTest, relayOption) { } // This test checks that the code properly handles cases when -// there is RAI option, but there's no requested sub-option. +// there is a RAI option, but there's no requested sub-option. TEST_F(TokenTest, relayOptionNoSuboption) { // Insert relay option with sub-options 1 and 13 diff --git a/src/lib/eval/token.cc b/src/lib/eval/token.cc index b9e7c524de..78e080d24c 100644 --- a/src/lib/eval/token.cc +++ b/src/lib/eval/token.cc @@ -1,4 +1,4 @@ -// Copyright (C) 2015 Internet Systems Consortium, Inc. ("ISC") +// Copyright (C) 2015-2016 Internet Systems Consortium, Inc. ("ISC") // // This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this diff --git a/src/lib/eval/token.h b/src/lib/eval/token.h index e330b3f15f..6b512175a2 100644 --- a/src/lib/eval/token.h +++ b/src/lib/eval/token.h @@ -1,4 +1,4 @@ -// Copyright (C) 2015 Internet Systems Consortium, Inc. ("ISC") +// Copyright (C) 2015-2016 Internet Systems Consortium, Inc. ("ISC") // // This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this @@ -283,8 +283,8 @@ public: /// @brief Represents a sub-option inserted by the DHCPv4 relay. /// /// DHCPv4 relays insert sub-options in option 82. This token attempts to extract -/// such sub-options. Note it is radically different than in DHCPv6 (possible -/// many encapsulation levels), thus separate classes for v4 and v6. +/// such sub-options. Note in DHCPv6 it is radically different (possibly +/// many encapsulation levels), thus there are separate classes for v4 and v6. /// /// This token can represent the following expressions: /// relay[13].text - Textual representation of sub-option 13 in RAI (option 82) @@ -294,9 +294,9 @@ public: class TokenRelay4Option : public TokenOption { public: - /// @brief Construtor for extracting sub-option from RAI (option 82) + /// @brief Constructor for extracting sub-option from RAI (option 82) /// - /// @param option_code code of the searched sub-option + /// @param option_code code of the requested sub-option /// @param rep_type code representation (currently .hex and .text are supported) TokenRelay4Option(const uint16_t option_code, const RepresentationType& rep_type);