summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormaximilian attems <maks@debian.org>2007-04-16 20:33:52 +0200
committermaximilian attems <maks@debian.org>2007-04-16 20:33:52 +0200
commit2b382bf18e47765e9f3bb1963008f8ee1a46cf97 (patch)
treeb6c1bbc0f3f02be8e73e0317260377479ae00a51
parentadda784dc1289b3ceb0ce207850ef9a93102febe (diff)
downloadinitramfs-tools-2b382bf18e47765e9f3bb1963008f8ee1a46cf97.tar.gz
initramfs-tools-2b382bf18e47765e9f3bb1963008f8ee1a46cf97.zip
fix regexes to always use posix char classes and release 0.87
needs the -regextype posix-extended switch for find, also it seems 0.86 disgarded uselessly uppercase scripts (they might be distasteful ;)
-rw-r--r--debian/changelog7
-rwxr-xr-xmkinitramfs8
-rw-r--r--scripts/functions4
3 files changed, 12 insertions, 7 deletions
diff --git a/debian/changelog b/debian/changelog
index c5a5e01..0d77ff9 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,4 +1,4 @@
-initramfs-tools (0.87) UNRELEASED; urgency=low
+initramfs-tools (0.87) unstable; urgency=low
[ maximilian attems ]
* scripts/functions: reduce_satisfied() needs to ignore the same set as
@@ -6,6 +6,9 @@ initramfs-tools (0.87) UNRELEASED; urgency=low
boot script may cause circular panic. (closes: 418509)
* Add blacklist boot param, disabling the load of specific modules inside
the initramfs. Still needs to be passed via tmpfs to the rootfs.
+ * mkinitramfs, scripts/functions: Fix regexes to always use posix character
+ classes. Based on a patch by Meelis Roos <mroos@linux.ee>.
+ (closes: 419062)
[ David Härdeman ]
* Add support for loading keymaps. (closes: 337663)
@@ -16,7 +19,7 @@ initramfs-tools (0.87) UNRELEASED; urgency=low
* Bump standards version, no changes necessary.
* debian/scripts: Print settings from initramfs.conf in reportbug script.
- -- maximilian attems <maks@debian.org> Mon, 16 Apr 2007 19:54:04 +0200
+ -- maximilian attems <maks@debian.org> Mon, 16 Apr 2007 20:21:30 +0200
initramfs-tools (0.86) unstable; urgency=low
diff --git a/mkinitramfs b/mkinitramfs
index b3514fc..e7b9b13 100755
--- a/mkinitramfs
+++ b/mkinitramfs
@@ -84,7 +84,8 @@ fi
. "${CONFDIR}/initramfs.conf"
EXTRA_CONF=''
for i in /usr/share/initramfs-tools/conf.d/* ${CONFDIR}/conf.d/*; do
- EXTRA_CONF="${EXTRA_CONF} $(basename $i | grep '^[a-z0-9][a-z0-9\._-]*$' | grep -v '\.dpkg-.*$')";
+ EXTRA_CONF="${EXTRA_CONF} $(basename $i \
+ | grep '^[[:alnum:]][[:alnum:]\._-]*$' | grep -v '\.dpkg-.*$')";
done
for i in ${EXTRA_CONF}; do
if [ -e ${CONFDIR}/conf.d/${i} ]; then
@@ -204,13 +205,14 @@ copy_exec /usr/share/initramfs-tools/init /init
# add existant boot scripts
for b in $(cd /usr/share/initramfs-tools/scripts/ && find . \
- -regex '.*/[a-z0-9_]+$' -type f); do
+ -regextype posix-extended -regex '.*/[[:alnum:]_]+$' -type f); do
[ -d "${DESTDIR}/scripts/$(dirname "${b}")" ] \
|| mkdir -p "${DESTDIR}/scripts/$(dirname "${b}")"
cp -p "/usr/share/initramfs-tools/scripts/${b}" \
"${DESTDIR}/scripts/$(dirname "${b}")"
done
-for b in $(cd "${CONFDIR}/scripts" && find . -regex '.*/[a-z0-9_]+$' -type f); do
+for b in $(cd "${CONFDIR}/scripts" && find . \
+ -regextype posix-extended -regex '.*/[[:alnum:]_]+$' -type f); do
[ -d "${DESTDIR}/scripts/$(dirname "${b}")" ] \
|| mkdir -p "${DESTDIR}/scripts/$(dirname "${b}")"
cp -p "${CONFDIR}/scripts/${b}" "${DESTDIR}/scripts/$(dirname "${b}")"
diff --git a/scripts/functions b/scripts/functions
index 00fcf3d..0b8d1e8 100644
--- a/scripts/functions
+++ b/scripts/functions
@@ -87,7 +87,7 @@ set_initlist()
for si_x in ${initdir}/*; do
# only allow variable name chars
case ${si_x#${initdir}/} in
- *[!A-Za-z0-9_]*)
+ *[![:alnum:]_]*)
continue
;;
esac
@@ -110,7 +110,7 @@ reduce_satisfied()
for rs_y in ${deplist}; do
# only allow variable name chars
case ${rs_y} in
- *[!A-Za-z0-9_]*)
+ *[![:alnum:]_]*)
continue
;;
esac