Re: Minor patch to oaf-slay



> +			# NOTE the blank after the filep without it we will
> +			# match any command line containing the name of a server
> +			# eg vi server/main.c
> +			if ($el =~m/$filep[:blank:]/ ) {

I think you need a ? after the [:blank:], or it will miss, eg
"evolution" with no arguments.

Also, this protects against "vi server/main.c", but not
"make -C server install"

>  					@ps_array = split(' ', $el);
>  					$list_array[$index]=$ps_array[0]."\t".$ps_array[1]."\n";

But if you do the split first, and then compare $ps_array[1] against
/^$filep[:blank:]?/, I think it should all work...

-- Dan




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]