public void writeHead(OutputStream out) {
FileInputStream fileStream = null;
try {
fileStream = new FileInputStream(articleFile);
MailHeaders headers = new MailHeaders(fileStream);
byte[] headerBuffer = headers.toByteArray();
int headerBufferLength = headerBuffer.length;
// Write the headers excluding the final CRLF pair
if (headerBufferLength > 2) {
out.write(headerBuffer, 0, (headerBufferLength - 2));
}