diff --git a/jmc.py b/jmc.py
index 8c15dbe..575470c 100755
--- a/jmc.py
+++ b/jmc.py
@@ -47,6 +47,9 @@ def main(config_file = "jmc.xml", isDebug = 0):
str(sys.exc_value)
sys.exit(1)
+ pidfile = open(config.get_content("config/pidfile"), "w")
+ pidfile.write(str(os.getpid()))
+ pidfile.close()
mailconnection.default_encoding = config.get_content("config/mail_default_encoding")
print "creating component..."
mailcomp = MailComponent(config.get_content("config/jabber/service"), \
diff --git a/jmc.xml b/jmc.xml
index 7a3f58d..c1d1d10 100644
--- a/jmc.xml
+++ b/jmc.xml
@@ -14,6 +14,7 @@
DBM
/var/spool/jabber
+ /var/run/jabber/jmc.pid
5
iso-8859-1
diff --git a/tests/jmc-test.xml b/tests/jmc-test.xml
index 875c883..c90e6a9 100644
--- a/tests/jmc-test.xml
+++ b/tests/jmc-test.xml
@@ -13,6 +13,7 @@
SQLite
+ jmc.pid
.
5
iso-8859-15