Fix off-by-one error in test_util_make_environment

This commit is contained in:
Patrick Mézard 2012-02-20 14:12:50 +01:00
parent 3a94530595
commit 857ae345c8

View File

@ -1945,7 +1945,8 @@ test_util_make_environment(void *ptr)
"HOME=/home/foozer\000" "HOME=/home/foozer\000"
"PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/bin\000" "PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/bin\000"
"\000"; "\000";
size_t expected_windows_env_block_len = sizeof(expected_windows_env_block); size_t expected_windows_env_block_len =
sizeof(expected_windows_env_block) - 1;
smartlist_t *env_vars = smartlist_new_from_text_lines(env_vars_string); smartlist_t *env_vars = smartlist_new_from_text_lines(env_vars_string);
smartlist_t *env_vars_sorted = smartlist_new(); smartlist_t *env_vars_sorted = smartlist_new();