[Raw Msg Headers][Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

totally unnecessary patch



If anyone actually uses zmailmon in the util directory, the
following patch might be useful. (I am using it.)

Explanation:

First hunk:
	GNU test doesn't want to believe a null string is the same
	as zero. Hopefully no "test" would think a 0something
	number is octal...

Second hunk:
	msg has changed abouot 4 or 5 years ago; current versions
	of msg only allow a message to be passed via the "-m" flag.

-------------------------------------------------------------------
--- zmailmon.dist	Wed Jul  8 17:07:03 1992
+++ zmailmon	Sun Nov  3 21:55:43 1996
@@ -30,10 +30,10 @@
 case "$OK" in
         0) : no point in further checking;;
         *)
-rmsgs=`fgrep "in router queue" /tmp/rep.$$ | awk '{print $1}'`
-smsgs=`fgrep "in scheduler queue" /tmp/rep.$$ | awk '{print $1}'`
-tmsgs=`fgrep "in transport queue" /tmp/rep.$$ | awk '{print $1}'`
-dmsgs=`fgrep "messages deferred" /tmp/rep.$$ | awk '{print $1}'`
+rmsgs=0`fgrep "in router queue" /tmp/rep.$$ | awk '{print $1}'`
+smsgs=0`fgrep "in scheduler queue" /tmp/rep.$$ | awk '{print $1}'`
+tmsgs=0`fgrep "in transport queue" /tmp/rep.$$ | awk '{print $1}'`
+dmsgs=0`fgrep "messages deferred" /tmp/rep.$$ | awk '{print $1}'`
 if [ "$rmsgs" -gt $RQUEUE ] ; then OK=0; fi
 if [ "$smsgs" -gt $SQUEUE ] ; then OK=0; fi
 if [ "$tmsgs" -gt $TQUEUE ] ; then OK=0; fi
@@ -46,6 +46,6 @@
 # Now we actually buzz people.
 case $OK in
         1) ;;
-        0) msg $PEOPLE "$MESSAGE" 2>/dev/null;;
+        0) msg -m "$MESSAGE" $PEOPLE 2>/dev/null;;
 esac
 rm -f /tmp/rep.$$
-------------------------------------------------------------------