Commit c8d9b90
committed
testenv: fix the --legacy-ip option implementation
The implementation of the '--legacy-ip' option was broken in two places.
First, the 'ip route' program was called to add a IPv4 route with a network
prefix ending with the IPv6 '::' notation.
Second, the 'get_num' function returns the number of a test environment in hex,
and this return value is used when defining IPv6 and/or IPv4 network prefixes.
In the IPv4 case we need to convert it to decimal, or some prefixes, starting
from the tenth test environment, e.g., '10.11.a' or '10.11.b', will be incorrect.
Signed-off-by: Anton Protopopov <a.s.protopopov@gmail.com>1 parent cab4d29 commit c8d9b90
1 file changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
196 | 196 | | |
197 | 197 | | |
198 | 198 | | |
199 | | - | |
| 199 | + | |
200 | 200 | | |
201 | 201 | | |
202 | 202 | | |
| |||
240 | 240 | | |
241 | 241 | | |
242 | 242 | | |
243 | | - | |
| 243 | + | |
244 | 244 | | |
245 | 245 | | |
246 | 246 | | |
| |||
0 commit comments