Minor patch to oaf-slay
- From: Jody Goldberg <jgoldberg home com>
- To: gnome-components-list gnome org
- Subject: Minor patch to oaf-slay
- Date: Tue, 25 Sep 2001 10:20:44 -0400
After having oaf-slay kill my editor again I'm proposing a minor
patch.
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/oaf/ChangeLog,v
retrieving revision 1.181
diff -u -w -r1.181 ChangeLog
--- ChangeLog 2001/09/12 23:15:51 1.181
+++ ChangeLog 2001/09/25 14:18:14
@@ -1,3 +1,8 @@
+2001-09-25 Jody Goldberg <jgoldberg home com>
+
+ * test/oaf-slay.in : Do not kill processes that just have a server
+ name somewhere on the command line. eg vi server/main.c
+
2001-09-12 Darin Adler <darin bentspoon com>
* oafd/ac-corba.c: Add a missing include of config.h.
Index: test/oaf-slay.in
===================================================================
RCS file: /cvs/gnome/oaf/test/oaf-slay.in,v
retrieving revision 1.2
diff -u -w -r1.2 oaf-slay.in
--- test/oaf-slay.in 2001/09/04 03:46:54 1.2
+++ test/oaf-slay.in 2001/09/25 14:18:14
@@ -114,7 +114,7 @@
# oafd needs to be last.
#
- if ($line ne "oafd") {
+ if ($line ne "oafd" and not($line =~m/^OAFIID:/)) {
push @file_process, $line;
}
} #end while(<FILE>)
@@ -129,18 +129,18 @@
foreach $filep (@file_process) {
- if (not($filep =~m/^OAFIID:/)) {
-
# Search through @ps_result and look for matches
#
foreach $el (@ps_result) {
chomp $el;
- if ($el =~m/$filep/ ) {
+ # 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:]/ ) {
@ps_array = split(' ', $el);
$list_array[$index]=$ps_array[0]."\t".$ps_array[1]."\n";
$process_pids[$index]=$ps_array[0]."\n";
$index++;
- }
}
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]