summaryrefslogtreecommitdiff
path: root/docs/manual/smsd/smsd.rst
diff options
context:
space:
mode:
authorMichal Čihař <nijel@debian.org>2017-03-28 18:36:52 +0200
committerMichal Čihař <nijel@debian.org>2017-03-28 18:36:52 +0200
commit1ac8e6ba4f4e173dbddb2d9de3583d16fa72a38d (patch)
tree19e59afa1e8e9a7a7c7d1214489734fb4cf45d2a /docs/manual/smsd/smsd.rst
parent3a78e0f2c53d76519c00e352a6b2e089e5531cf6 (diff)
parent6441db396f58e65ae6240cf3a8504012b2937ef4 (diff)
Merge tag 'upstream/1.38.2'
Upstream version 1.38.2 # gpg: Podpis vytvořen Út 28. březen 2017, 18:36:52 CEST # gpg: použití RSA klíče 87E673AF83F6C3A0C344C8C3F4AA229D4D58C245 # gpg: Dobrý podpis od „Michal Čihař <michal@cihar.com>“ [absolutní] # gpg: alias „Michal Čihař <nijel@debian.org>“ [absolutní] # gpg: alias „[jpeg image of size 8848]“ [absolutní]
Diffstat (limited to 'docs/manual/smsd/smsd.rst')
-rw-r--r--docs/manual/smsd/smsd.rst24
1 files changed, 24 insertions, 0 deletions
diff --git a/docs/manual/smsd/smsd.rst b/docs/manual/smsd/smsd.rst
index 78ecc2b..6314add 100644
--- a/docs/manual/smsd/smsd.rst
+++ b/docs/manual/smsd/smsd.rst
@@ -232,6 +232,30 @@ workaround this limitation by suspending SMSD temporarily using `SIGUSR1` and
kill -SIGUSR2 $SMSD_PID
fi
+Or even create a `gammu-safe` script:
+
+.. code-block:: sh
+ #!/bin/bash
+ SMSD_PID=`pidof gammu-smsd`
+ if [ -z "$SMSD_PID" ] ; then
+ gammu $@
+ else
+ tty=$(lsof |grep -E "gammu-sms\s+$SMSD_PID\s+.*/dev/tty*"|awk {'print $NF'})
+ kill -SIGUSR1 $SMSD_PID
+ while test "$(fuser $ttyfuser $tty 2> /dev/null|xargs)" = $SMSD_PID
+ do
+ sleep 1
+ done
+ sleep 1
+ gammu $@
+ kill -SIGUSR2 $SMSD_PID
+ while test "$(fuser $ttyfuser $tty 2> /dev/null|xargs)" != $SMSD_PID
+ do
+ sleep 1
+ done
+ sleep 1
+ fi
+
Known Limitations
-----------------