[pmg-devel] applied: [PATCH pmg-api v2 06/10] fix result verification for invalid mails

Thomas Lamprecht t.lamprecht at proxmox.com
Fri Oct 4 09:34:42 CEST 2019


On 9/30/19 2:55 PM, Dominik Csapak wrote:
> in case we cannot parse the mail to produce any sensible html/text
> output, we got a 'result verification error', instead show 'No Content'
> 
> Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
> ---
> changes from v1:
> * change error message
>  src/PMG/API2/Quarantine.pm | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/PMG/API2/Quarantine.pm b/src/PMG/API2/Quarantine.pm
> index feae798..ec93e80 100644
> --- a/src/PMG/API2/Quarantine.pm
> +++ b/src/PMG/API2/Quarantine.pm
> @@ -851,7 +851,7 @@ __PACKAGE__->register_method ({
>  	    my $viewimages = $cfg->get('spamquar', 'viewimages');
>  	    my $allowhref = $cfg->get('spamquar', 'allowhrefs');
>  
> -	    $res->{content} = PMG::HTMLMail::email_to_html($path, $raw, $viewimages, $allowhref);
> +	    $res->{content} = PMG::HTMLMail::email_to_html($path, $raw, $viewimages, $allowhref) // 'unable to parse mail';
>  
>  	    # to make result verification happy
>  	    $res->{file} = '';
> 

applied this one, as it was a general fix not much to do with the
series in general.



More information about the pmg-devel mailing list