commit 54d63266203d6c9419f958845e3fe8170a21273c
parent a668eeab1eb16e4b4e131d379704723359fe0723
Author: Jan Pobrislo <ccx@webprojekty.cz>
Date: Wed, 13 Aug 2014 13:49:58 +0200
"realpath" the @filename macro
Diffstat:
1 file changed, 3 insertions(+), 0 deletions(-)
diff --git a/bin/aat.awk b/bin/aat.awk
@@ -156,6 +156,9 @@ function call_macro(name, args, file_old) {
else if(name == "filename"){
tok_type=T_AWK
args = filename
+ while(match(args, /[^/]+\/..\//) != 0) {
+ gsub(/[^/]+\/..\//, "", args)
+ }
gsub(/["\\]/, "\\&", args)
token("filename = \"" args "\"\n")
}