From cd195fa267b1869156e6d675032fdafe3035bf5e Mon Sep 17 00:00:00 2001 From: Jacob Erlbeck Date: Tue, 6 Aug 2013 14:29:15 +0200 Subject: vty: Support multi-char separators and end strings In vty_cmd_string_from_valstr() include the real string lengths of the sep and end arguments into the buffer size calculation. --- tests/vty/vty_test.ok | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/vty') diff --git a/tests/vty/vty_test.ok b/tests/vty/vty_test.ok index 9ff68c88..baec2499 100644 --- a/tests/vty/vty_test.ok +++ b/tests/vty/vty_test.ok @@ -1,3 +1,3 @@ Going to test vty_cmd_string_from_valstr() -Tested with %s-strings, resulting cmd = '[prefix%s%s%s%s%s][foo%s%s%s%s%s][sep%s%s%s%s%s][' +Tested with %s-strings, resulting cmd = '[prefix%s%s%s%s%s][foo%s%s%s%s%s][sep%s%s%s%s%s][bar%s%s%s%s%s][end%s%s%s%s%s]' All tests passed -- cgit v1.2.3