From: pdontthink Date: Wed, 25 Oct 2006 01:54:54 +0000 (+0000) Subject: Attachment hooks were not registering. Also, brace count code had no effect where... X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=02473e22f55751d172fd081c55a1c29af870fb98;p=squirrelmail.git Attachment hooks were not registering. Also, brace count code had no effect where it was. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@11934 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- diff --git a/config/conf.pl b/config/conf.pl index a3d1c7f7..894a2b19 100755 --- a/config/conf.pl +++ b/config/conf.pl @@ -5100,13 +5100,6 @@ PLUGIN: for ( $ct = 0 ; $ct <= $#plugins ; $ct++ ) { $inside_init_fxn = 1; - # throw away lines that are not exactly one "brace set" deep - # - if ($brace_count > 1) { - next; - } - - # count open braces # if ($line =~ /{/) { @@ -5128,6 +5121,13 @@ PLUGIN: for ( $ct = 0 ; $ct <= $#plugins ; $ct++ ) { } + # throw away lines that are not exactly one "brace set" deep + # + if ($brace_count > 1) { + next; + } + + # also not interested in lines that are not # hook registration points # @@ -5160,7 +5160,7 @@ PLUGIN: for ( $ct = 0 ; $ct <= $#plugins ; $ct++ ) { $options[1] =~ s/\\'/'/g; $options[1] =~ s/\\\\/\\/g; - if ( $options[0] =~ /^squirrelmail_plugin_hooks\s*\[\s*['"]([a-z0-9._-]+)['"]\s*\]\s*\[\s*['"]([0-9a-z._-]+)['"]\s*\]/i ) { + if ( $options[0] =~ /^squirrelmail_plugin_hooks\s*\[\s*['"]([a-z0-9 \/._*-]+)['"]\s*\]\s*\[\s*['"]([0-9a-z._-]+)['"]\s*\]/i ) { $hook_name = $1; $hooked_plugin_name = $2; # Note: if we wanted to stop plugins from registering