aboutsummaryrefslogtreecommitdiffstats
path: root/tools/killev
diff options
context:
space:
mode:
authornobody <nobody@localhost>2003-01-09 14:55:40 +0800
committernobody <nobody@localhost>2003-01-09 14:55:40 +0800
commit4f34b87b2cd931be213c453c0a9c23e513a81953 (patch)
tree1e12040caec266ee2e16460c80583d4af3687d10 /tools/killev
parent45d0c39700d2d6ee12f45c17778d69f3119ba078 (diff)
downloadgsoc2013-evolution-GNOME_UTILS_2_2_1.tar
gsoc2013-evolution-GNOME_UTILS_2_2_1.tar.gz
gsoc2013-evolution-GNOME_UTILS_2_2_1.tar.bz2
gsoc2013-evolution-GNOME_UTILS_2_2_1.tar.lz
gsoc2013-evolution-GNOME_UTILS_2_2_1.tar.xz
gsoc2013-evolution-GNOME_UTILS_2_2_1.tar.zst
gsoc2013-evolution-GNOME_UTILS_2_2_1.zip
This commit was manufactured by cvs2svn to create tagGNOME_UTILS_2_2_1
'GNOME_UTILS_2_2_1'. svn path=/tags/GNOME_UTILS_2_2_1/; revision=19339
Diffstat (limited to 'tools/killev')
-rwxr-xr-xtools/killev142
1 files changed, 0 insertions, 142 deletions
diff --git a/tools/killev b/tools/killev
deleted file mode 100755
index dc8920c271..0000000000
--- a/tools/killev
+++ /dev/null
@@ -1,142 +0,0 @@
-#!/usr/bin/perl
-
-# set to 1 if you want some extra spew
-$debug=0;
-
-# Interfaces of CORBA servers that need to die.
-@idls = ("IDL:GNOME/Evolution/ShellComponent:1.0",
- "IDL:GNOME/Evolution/CalFactory:1.0",
- "IDL:GNOME/Evolution/BookFactory:1.0",
- "IDL:GNOME/Evolution/Importer:1.0",
- "IDL:GNOME/Evolution/IntelligentImporter:1.0",
- "IDL:GNOME/Evolution/Shell:1.0",
- "IDL:GNOME/Spell/Checker:0.1");
-
-
-# IIDs of specific CORBA servers that need to die that don't implement
-# useful interfaces (for querying, anyway)
-@iids = ("OAFIID:GNOME_Evolution_Calendar_AlarmNotify_Factory",
- "OAFIID:GNOME_GtkHTML_Editor_Factory:1.1",
- "OAFIID:Bonobo_Moniker_xmldb_Factory");
-
-##
-## You shouldn't have to change anything below this point
-##
-
-$sysname=`uname -s`;
-chop $sysname;
-
-if ($sysname eq "SunOS") {
- $killcmd="pkill";
-}
-else {
- $killcmd="killall";
-}
-
-sub kill_exe {
- my ($exe_name) = @_;
- my $lt_name = "lt-$exe_name";
- my $sub_exe_name = substr ($exe_name, 0, 16);
- my $sub_lt_name = substr ($lt_name, 0, 16);
-
- printf ("killing $exe_name\n");
-
- $redirect = "2> /dev/null";
-
- print "$killcmd -9 $exe_name\n" if ($debug);
- `$killcmd -9 $exe_name $redirect`;
-
- print "$killcmd -9 $lt_name\n" if ($debug);
- `$killcmd -9 $lt_name $redirect`;
-
- print "$killcmd -9 $sub_exe_name\n" if ($debug);
- `$killcmd -9 $sub_exe_name $redirect`;
-
- print "$killcmd -9 $sub_lt_name\n" if ($debug);
- `$killcmd -9 $sub_lt_name $redirect`;
-}
-
-sub kill_exes {
- while (($key, $value) = each %things_to_kill) {
- &kill_exe($key);
- }
-}
-
-sub add_exe {
- my ($exe_name) = @_;
- $things_to_kill{$exe_name} = $exe_name;
-}
-
-sub add_factory {
- my ($factory_iid) = @_;
-
- open (FACTORY_QUERY, "oaf-client -q -s \"iid == '$factory_iid'\"|");
- while (<FACTORY_QUERY>) {
- if (/type exe, location (.*)$/) {
- &add_exe ($1);
- }
- }
- close (FACTORY_QUERY);
-}
-
-# we need to do separate queries for iids because cvs OAF loses when
-# you do more than one 'iid ==' separated by OR's. It returns a list
-# of all CORBA servers. Cool, eh?
-
-sub run_iid_query {
- my $iid_query;
-
- for ($i = 0; $i < @iids; $i++) {
- $iid_query = "iid == '$iids[$i]'";
-
- #printf ("$iid_query\n");
-
- open (QUERY, "oaf-client -q -s \"$iid_query\"|");
- while (<QUERY>) {
- if (/type exe, location (.*)$/) {
- &add_exe ($1);
- }
- elsif (/type factory, location (.*)$/) {
- &add_factory ($1);
- }
- }
- close (QUERY);
- }
-}
-
-sub run_query {
- my ($idl_query, $iid_query, $oaf_query);
-
- $idl_query = "";
- for ($i = 0; $i < @idls; $i++) {
- $idl_query .= "repo_ids.has('$idls[$i]')";
- $idl_query .= " OR " if ($i < @idls - 1);
- }
-
- #$iid_query = "";
- #for ($i = 0; $i < @iids; $i++) {
- # $iid_query .= "iid == '$iids[$i]'";
- # $iid_query .= " OR " if ($i < @iids - 1);
- #}
-
- $oaf_query = $idl_query;
- #$oaf_query .= " OR $iid_query" if (@iids > 0);
-
- #printf ("$oaf_query\n");
-
- open (QUERY, "oaf-client -q -s \"$oaf_query\"|");
-
- while (<QUERY>) {
- if (/type exe, location (.*)$/) {
- &add_exe ($1);
- }
- elsif (/type factory, location (.*)$/) {
- &add_factory ($1);
- }
- }
- close (QUERY);
-}
-
-&run_query ();
-&run_iid_query ();
-&kill_exes();