From 01bab7f316de6862a82fefda1d8374f41c75ca06 Mon Sep 17 00:00:00 2001
From: Fredrik Noring <noring@nocrew.org>
Date: Tue, 23 Nov 1999 00:34:54 +0100
Subject: [PATCH] Added append_path as an alternative to combine_path (avoiding
 security problems with double-dots).

Rev: src/testsuite.in:1.231
---
 src/testsuite.in | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/testsuite.in b/src/testsuite.in
index 5fd054f569..8ef87ec632 100644
--- a/src/testsuite.in
+++ b/src/testsuite.in
@@ -1,4 +1,4 @@
-test_true([["$Id: testsuite.in,v 1.230 1999/11/20 12:43:19 mirar Exp $"]])
+test_true([["$Id: testsuite.in,v 1.231 1999/11/22 23:34:54 noring Exp $"]])
 
 cond([[all_constants()->_verify_internals]],
 [[
@@ -3025,6 +3025,11 @@ test_eq([[combine_path("/","../../foo")]],"/foo")
 test_eq([[combine_path("./foobar/.","..")]],".")
 test_eq([[combine_path("/","foo","bar","gazonk")]],"/foo/bar/gazonk")
 
+// - Stdio.append_path
+test_eq([[ Stdio.append_path("../foo/", "../bar") ]], "../foo/bar")
+test_eq([[ Stdio.append_path("../foo/", "../bar", "../baz") ]], "../foo/bar/baz")
+test_eq([[ Stdio.append_path("../foo/", "../bar", "../baz", "../fie/../faz") ]], "../foo/bar/baz/faz")
+
 // - compile_file
 // FIXME: add tests for compile_file
 
-- 
GitLab