From 19eef8a09ba5b2b3a88eb91001e24c18c9a82611 Mon Sep 17 00:00:00 2001 From: rillig Date: Fri, 18 Nov 2005 11:07:27 +0000 Subject: Added a few FIXMEs at places where this program might fail unexpectedly. --- mk/scripts/mkdatabase | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'mk/scripts') diff --git a/mk/scripts/mkdatabase b/mk/scripts/mkdatabase index b738dfb06c9..845e5a688c4 100755 --- a/mk/scripts/mkdatabase +++ b/mk/scripts/mkdatabase @@ -1,5 +1,5 @@ #!/bin/sh -# $NetBSD: mkdatabase,v 1.8 2005/11/18 10:58:37 rillig Exp $ +# $NetBSD: mkdatabase,v 1.9 2005/11/18 11:07:27 rillig Exp $ # # Script for generating a database with complete dependency information # for a particular package @@ -139,6 +139,7 @@ yes) set -v;; esac if [ ! -d "$TMPDIR" ]; then + # FIXME: wouldn't it be better to fail in this case? mkdir -p "$TMPDIR" fi @@ -151,6 +152,8 @@ case ${DATABASE} in ;; *) + # FIXME: wouldn't it be better to fail in this case? + # make sure we have the full path to the database file DATABASE=`pwd`/${DATABASE} ;; @@ -172,6 +175,7 @@ if [ $append_flag = yes ]; then case $debug_flag in yes) echo "Looking for $pkgpath before appending";; esac + # FIXME: $pkgpath may contain special regex characters. if grep "^index $pkgpath " "${DATABASE}" >/dev/null 2>&1 ; then echo "$prompt $pkgpath has already been depended. Skipping..." exit 0 -- cgit v1.2.3