Ran into a problem where sometimes messages would fail to be saved. Only on replies, and the messages would actually be accepted by the SMTP server and sent, but Roundcube would report 'An error occured while saving' due to failure to save to Sent folder. Same failure if you try to save to Drafts.
Ok. So I tracked this down, and found that when email with a multi-line References line like so confuses Roundcube:
References: <76707827F72F4A79974C7F05B7ECE187@Victoria>
<91ebb6008a5244d3abeb9773e4c515a5@ncf.ca>
<326CDEF6E5A9447298092EE87897B05E@Victoria>
<0JYP00JTDT6CHH@saruman.ncf.ca>
Roundcube is able to access these messages fine, but the generated reply message is mangled:
Date: Wed, 02 Apr 2008 16:55:55 -0400
From:
Subject: Re: test Wed, 02 Apr 2008 16:35:00 -0400
To:
<91ebb6008a5244d3abeb9773e4c515a5@ncf.ca>
<326CDEF6E5A9447298092EE87897B05E@Victoria> <0JYP00JTDT6CHH@saruman.ncf.ca>
+<20080402203549.GA3366@ncf.ca>
Message-ID: <77b39ca77eb1eb8c5943a2c5ce3741fe@ncf.ca>
X-Sender:
Received: from 206-248-168-7.dsl.ncf.ca [206.248.168.7] with HTTP/1.1 (POST);
Wed, 02 Apr 2008 16:55:55 -0400
User-Agent: RoundCube Webmail/0.1
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 8bit
As you can see - the References header seems to turn into a newline, breaking the headers.