<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">18.07.2017 17:05, Dominic Raferd пишет:<br>
    </div>
    <blockquote type="cite"
cite="mid:CAF9Mo3J3OjJVJOL1BNg2noVqP9Pcw1YaLj8xgA+UP9yuRQw9BQ@mail.gmail.com">
      <div dir="ltr">
        <div class="gmail_default" style="font-size:small"><br>
        </div>
        <div class="gmail_extra"><br>
          <div class="gmail_quote">On 18 July 2017 at 12:24, Dmitry
            Melekhov <span dir="ltr"><<a href="mailto:dm@belkam.com"
                target="_blank" moz-do-not-send="true">dm@belkam.com</a>></span>
            wrote:<br>
            <blockquote class="gmail_quote" style="margin:0px 0px 0px
              0.8ex;border-left:1px solid
              rgb(204,204,204);padding-left:1ex">Hello!<br>
              <br>
              <br>
              I run Ubuntu 16.04, it has 2.10.1 of amavisd-new  .<br>
              <br>
              If file is blocked by amavis, let's say it .exe file, and
              this file has UTF8 name (let's say Тест.exe), then<br>
              <br>
              amavis dies, without DSN generation and message stucks in
              queue:<br>
              <br>
              <br>
              open body: Invalid argument at
              /usr/local/share/perl/5.22.1/M<wbr>IME/Entity.pm line
              1878, <GEN38> line 17244.): id=01268-01 at
              /usr/sbin/amavisd-new line 15165<br>
              <br>
              <br>
              Could you tell me how to fix this problem?<br>
              <br>
              <br>
              Thank you!<br>
              <br>
              <br>
            </blockquote>
            <div><br>
            </div>
            <div class="gmail_default" style="font-size:small">Just a
              thought, but ​looking at
              /etc/amavis/conf.d/30-template_localization, it might be
              worth trying in /etc/amavis/conf.d/50-user:</div>
            <div class="gmail_default" style="font-size:small">​$hdr_encoding
              = 'utf8';</div>
            <div class="gmail_default" style="font-size:small">​$bdy_encoding
              = 'utf8';<br>
            </div>
          </div>
        </div>
        <div class="gmail_extra"><br>
        </div>
      </div>
    </blockquote>
    <p>I already have this:</p>
    <p><br>
    </p>
    <p>/etc/amavis/conf.d# grep utf *<br>
      30-template_localization:$hdr_encoding = 'utf-8';<br>
      30-template_localization:$bdy_encoding = 'utf-8';<br>
    </p>
    <p>btw, <br>
    </p>
    <div class="boardCommentBody">
      <div class="comment-text" itemprop="commentText">
        <p>As temporary workaround I changed</p>
        <p># my $IO = $self->open("r") || die "open body: $!";<br>
              my $IO = $self->open("r") || return error "open body:
          $!";</p>
        <p>at /usr/local/<wbr>share/perl/<wbr>5.22.1/<wbr>MIME/Entity.<wbr>pm
          line 1878</p>
        <p>This results in message (not full , but) generation and no
          messages stuck in queue..</p>
        <p><br>
        </p>
        <p>btw, MIME::Entity have bug open since 2015</p>
        <p><a class="moz-txt-link-freetext" href="https://rt.cpan.org/Public/Bug/Display.html?id=105377">https://rt.cpan.org/Public/Bug/Display.html?id=105377</a><br>
        </p>
        <p>some software already created workaround for this, but not
          amavis :-(</p>
        <p><br>
        </p>
        <p><br>
        </p>
      </div>
    </div>
  </body>
</html>