Re: smtpd reports - expectation management

2019-08-29 Thread Martijn van Duren
On 8/29/19 8:53 AM, gil...@poolp.org wrote:
> 29 août 2019 07:02 "Martijn van Duren"  a 
> écrit:
> 
>> Since we don't support any smtp-out events at time of writing, so we
>> might as well throw an error if people try to register one. This way
>> people won't be surprised if the registration succeeds, but no event
>> ever arrives.
>>
>> OK?
>>
> 
> no warning for unused smtp_out ?

it's still used on lines 84, 93 and 155.
The one on line 155 is just never triggered. :-)
> 
> ok with ifdef-ing out smtp-out for now, i can bring it back.
> 
> for the record, smtp-out has been implemented and I have it running on my
> machines but it requires a rework of the filter session registration (not
> visible to users) which I'm not comfortable to do before 6.6.

I assumed it's in the works.
> 
> 
>> Index: lka_report.c
>> ===
>> RCS file: /cvs/src/usr.sbin/smtpd/lka_report.c,v
>> retrieving revision 1.26
>> diff -u -p -r1.26 lka_report.c
>> --- lka_report.c 28 Aug 2019 15:50:36 - 1.26
>> +++ lka_report.c 29 Aug 2019 05:01:21 -
>> @@ -107,10 +107,13 @@ lka_report_register_hook(const char *nam
>> subsystem = _in;
>> hook += 8;
>> }
>> +#if 0
>> + /* No smtp-out event has been implemented yet */
>> else if (strncmp(hook, "smtp-out|", 9) == 0) {
>> subsystem = _out;
>> hook += 9;
>> }
>> +#endif
>> else
>> fatalx("Invalid message direction: %s", hook);



Re: smtpd reports - expectation management

2019-08-29 Thread gilles
29 août 2019 07:02 "Martijn van Duren"  a 
écrit:

> Since we don't support any smtp-out events at time of writing, so we
> might as well throw an error if people try to register one. This way
> people won't be surprised if the registration succeeds, but no event
> ever arrives.
> 
> OK?
> 

no warning for unused smtp_out ?

ok with ifdef-ing out smtp-out for now, i can bring it back.

for the record, smtp-out has been implemented and I have it running on my
machines but it requires a rework of the filter session registration (not
visible to users) which I'm not comfortable to do before 6.6.


> Index: lka_report.c
> ===
> RCS file: /cvs/src/usr.sbin/smtpd/lka_report.c,v
> retrieving revision 1.26
> diff -u -p -r1.26 lka_report.c
> --- lka_report.c 28 Aug 2019 15:50:36 - 1.26
> +++ lka_report.c 29 Aug 2019 05:01:21 -
> @@ -107,10 +107,13 @@ lka_report_register_hook(const char *nam
> subsystem = _in;
> hook += 8;
> }
> +#if 0
> + /* No smtp-out event has been implemented yet */
> else if (strncmp(hook, "smtp-out|", 9) == 0) {
> subsystem = _out;
> hook += 9;
> }
> +#endif
> else
> fatalx("Invalid message direction: %s", hook);



smtpd reports - expectation management

2019-08-28 Thread Martijn van Duren
Since we don't support any smtp-out events at time of writing, so we
might as well throw an error if people try to register one. This way
people won't be surprised if the registration succeeds, but no event
ever arrives.

OK?

martijn@

Index: lka_report.c
===
RCS file: /cvs/src/usr.sbin/smtpd/lka_report.c,v
retrieving revision 1.26
diff -u -p -r1.26 lka_report.c
--- lka_report.c28 Aug 2019 15:50:36 -  1.26
+++ lka_report.c29 Aug 2019 05:01:21 -
@@ -107,10 +107,13 @@ lka_report_register_hook(const char *nam
subsystem = _in;
hook += 8;
}
+#if 0
+   /* No smtp-out event has been implemented yet */
else if (strncmp(hook, "smtp-out|", 9) == 0) {
subsystem = _out;
hook += 9;
}
+#endif
else
fatalx("Invalid message direction: %s", hook);