summaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorThomas Hindoe Paaboel Andersen <phomes@gmail.com>2013-02-07 00:15:27 +0100
committerThomas Hindoe Paaboel Andersen <phomes@gmail.com>2013-02-07 00:38:09 +0100
commit7c2d80944afb4196f2eff614e8da1450dffcbeaa (patch)
tree5cdf18700cdfd9471eaee67e78661b286b9c98f2 /src/test
parentfa3cd7394c227ad38c5c09b2bc2d035e7fb14a76 (diff)
strv: add strv_print
Clearer, and spares the temp variable.
Diffstat (limited to 'src/test')
-rw-r--r--src/test/test-env-replace.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/src/test/test-env-replace.c b/src/test/test-env-replace.c
index cd596a6e16..ad5c991608 100644
--- a/src/test/test-env-replace.c
+++ b/src/test/test-env-replace.c
@@ -58,10 +58,7 @@ int main(int argc, char *argv[]) {
strv_free(a);
r = replace_env_argv((char**) line, (char**) env);
-
- STRV_FOREACH(i, r)
- printf("%s\n", *i);
-
+ strv_print(r);
strv_free(r);
t = normalize_env_assignment("foo=bar");
@@ -127,16 +124,13 @@ int main(int argc, char *argv[]) {
strv_free(a);
strv_free(b);
- STRV_FOREACH(i, r)
- printf("%s\n", *i);
+ strv_print(r);
printf("CLEANED UP:\n");
r = strv_env_clean(r);
- STRV_FOREACH(i, r)
- printf("%s\n", *i);
-
+ strv_print(r);
strv_free(r);
return 0;