<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
ZanDAhaR wrote:
<blockquote cite="mid44207BDB.60604@zandahar.net" type="cite">
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
Henrik Stoerner wrote:
<blockquote cite="mid20060321064605.GB20389@hswn.dk" type="cite">
<pre wrap="">On Tue, Mar 21, 2006 at 11:55:56AM +1100, ZanDAhaR wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Obviously sms has no subject so I am just wondering how the mailack
would work when recieving a message back ? By default does it look for
the ACK code only in the subject or does it also look in the body ? If
by default it only looks in the subject is it possible for us to bodge
up the code and tell it to read from the body & subject, or just the body ?
</pre>
</blockquote>
<pre wrap=""><!---->
Currently, it only looks in the subject for the ack code.
You can change that. Try this patch against the hobbit-mailack.c file:
Save it to a file, then run
patch hobbitd/hobbit-mailack.c </tmp/ack-body.patch
and re-compile with "make".
With this patch, you should be able to put a line into the message
body with
ack 129102
which is the ack code that is normally taken from the subject. You
can also put a
delay=120
to make the ack valid for 120 minutes.
The first line which does not match either of these is taken a the
ack message which is displayed on the webpage.
Regards,
Henrik
</pre>
<pre wrap=""><hr size="4" width="90%">
--- hobbitd/hobbit-mailack.c 2005/07/16 09:53:14 1.10
+++ hobbitd/hobbit-mailack.c 2006/03/21 06:40:59
@@ -64,8 +64,14 @@
duration = durationvalue(inbuf+6);
continue;
}
- /* Save the first line of the message body, but ignore blank lines */
+ else if ((subjectline == NULL) && (strncasecmp(inbuf, "ack ", 4) == 0)) {
+ /* Some systems cannot generate a subject. Allow them to ack
+ * via text in the message body. */
+ subjectline = (char *)malloc(1024);
+ snprintf(subjectline, 1023, "Subject: Hobbit [%s]", inbuf+4);
+ }
else if (*inbuf && !firsttxtline) {
+ /* Save the first line of the message body, but ignore blank lines */
firsttxtline = strdup(inbuf);
}
</pre>
<pre wrap=""><hr size="4" width="90%">
To unsubscribe from the hobbit list, send an e-mail to
<a class="moz-txt-link-abbreviated"
href="mailto:hobbit-unsubscribe@hswn.dk">hobbit-unsubscribe@hswn.dk</a>
</pre>
</blockquote>
Henrik I'm guessing by the timestamp on the patch file that you only
just created this patch after I mailed about it ?<br>
<br>
If so I cannot thank you enough and I'm sure many others will also.
Your constant work effort and dedication to hobbit is excellent :)<br>
<br>
Allan Spencer<br>
Corporate Learning Systems<br>
</blockquote>
Replying back to my own mail here but anyway<br>
<br>
Henrik will the contents of this patch be included in future releases
of hobbit ?<br>
<br>
Cheers<br>
<br>
Allan<br>
</body>
</html>