From: Junio C Hamano Date: Wed, 09 Sep 2026 18:15:29 GMT Subject: Re: [PATCH 2/2] lint-docs: check the guide list in command-list.txt Message-ID: In-Reply-To: <20260909052501.8448-3-taahol@utu.fi> Tuomas Ahola writes: > extract_variable () { > + file=${2:-../Makefile} > ( > - cat ../Makefile > + cat $file Now you are allowing arbitrary path to be fed to this function, you should prepare to accept arbitrary path, without assuming that $file has no $IFS whitespaces. I.e., cat "$file" > ) | > - make -C .. -f - print_variable 2>/dev/null | > + make -C $(dirname $file) -f - print_variable 2>/dev/null | Ditto. $file itself may have $IFS whitespaces, and the result of running dirname on it may too.