From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Delivered-To: caml-list@yquem.inria.fr Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by yquem.inria.fr (Postfix) with ESMTP id EF25CBCB0 for ; Fri, 17 Jun 2005 15:35:42 +0200 (CEST) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j5HDZg9g010372 for ; Fri, 17 Jun 2005 15:35:42 +0200 Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id PAA29944 for ; Fri, 17 Jun 2005 15:35:42 +0200 (MET DST) Received: from mail1.sun.ac.za (mail1.sun.ac.za [146.232.64.12]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id j5HDZfdc029540 for ; Fri, 17 Jun 2005 15:35:41 +0200 Received: from burger.sun.ac.za ([146.232.128.30]) by mail1.sun.ac.za with esmtp (Exim 4.34) id 1DjH0W-0005ov-7I for caml-list@inria.fr; Fri, 17 Jun 2005 15:35:40 +0200 Received: from js by burger.sun.ac.za with local (Exim 4.51) id 1DjH0W-0000Ln-6C for caml-list@inria.fr; Fri, 17 Jun 2005 15:35:40 +0200 Date: Fri, 17 Jun 2005 15:35:40 +0200 From: Johann Spies To: caml-list@inria.fr Subject: Netmime.readmessage and Netmime.writemessage - unexpected results Message-ID: <20050617133540.GB443@sun.ac.za> Mail-Followup-To: Johann Spies , caml-list@inria.fr Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.9i X-Miltered: at nez-perce with ID 42B2D1AE.001 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at concorde with ID 42B2D1AD.001 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; spies:01 jspies:01 netstream:01 netchannels:01 stdin:01 netchannels:01 stdout:01 spies:01 universiteit:01 stellenbosch:01 preface:98 021:98 short:01 behaviour:01 johann:01 X-Spam-Checker-Version: SpamAssassin 3.0.2 (2004-11-16) on yquem.inria.fr X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.2 X-Spam-Level: When I use the following code: let readmessage () = Netmime.read_mime_message (new Netstream.input_stream (new Netchannels.input_channel stdin));; let writemessage mesg = Netmime.write_mime_message (new Netchannels.output_channel stdout) mesg let _ = (*handle ( readmessage () )*) let f = readmessage () in writemessage f and pipe a short, multipart message through it using: $ cat multipart | disclaimer > multipart2 a "diff -y multipart multipart2" shows that an extra " ^I^I^I^I^I^I^I^I" (tabs) was added on to every line. I have expected an unaltered message. There was also some wording removed from the preface part of the message and from the epilogue. I have attached the original and filtered messages (multipart and multipart2) to illustrate the problem. When piping a simple message (not multipart) through this code "^M^I^I^I^I^I^I^I^I" was added to the headers only. How can I avoid this behaviour? Regards Johann -- Johann Spies Telefoon: 021-808 4036 Informasietegnologie, Universiteit van Stellenbosch "Many are the afflictions of the righteous; but the LORD delivereth him out of them all." Psalms 34:19