AW: [tbnl-devel] Upload of text files

Jaroslaw.Tomczak at sanofi-aventis.com Jaroslaw.Tomczak at sanofi-aventis.com
Tue Jul 5 13:58:42 UTC 2005


Hi Edi,

yes it seems to work for me.  Thank you!

Jaroslaw

> -----Ursprüngliche Nachricht-----
> Von: Edi Weitz [mailto:edi at agharta.de]
> Gesendet: Dienstag, 5. Juli 2005 13:08
> An: Tomczak, Jaroslaw PH/DE
> Cc: tbnl-devel at common-lisp.net
> Betreff: Re: [tbnl-devel] Upload of text files
> 
> 
> Hi!
> 
> On Mon, 4 Jul 2005 13:24:54 +0200, 
> <Jaroslaw.Tomczak at sanofi-aventis.com> wrote:
> 
> > I have noticed a minor problem when uploading text files with TBNL
> > (version 0.5.5 + Apache 2.0.54 + mod_lisp2 + LispWorks 4.4.5, all on
> > Windows 2000) -- DOS/Windows text files (CR/LF) have one empty line
> > appended at the end when uploaded.  Unix text files, however, are
> > transferred correctly.
> 
> Thanks for the report, I wasn't aware of this.
> 
> > Any ideas?
> 
> I sniffed around a bit and it looks like the problem is in the RFC
> 2388 library TBNL uses.  As a workaround try to replace the part of
> rfc2388.lisp which looks like
> 
>   (3 ;; first dash in dash-boundary
>    (cond ((char= char #\-)
>           (enqueue-char)
>           (setq state 4))
>          (t
>           (write-queued-chars)
>           (write-char char result)
>           (setq state 1))))
> 
> with this one:
> 
>   (3 ;; first dash in dash-boundary
>    (cond ((char= char #\-)
>           (enqueue-char)
>           (setq state 4))
>          ((char= char #\return)
>           (write-queued-chars)
>           (enqueue-char)
>           (setq state 2))
>          (t
>           (write-queued-chars)
>           (write-char char result)
>           (setq state 1))))
> 
> I haven't really tested if this breaks anything else but at least it
> seems to get rid of your problem.  Let me know if it works for you.
> 
> I'll send a bug report to Janis.
> 
> > P.S. Edi, thanks for your great libraries!
> 
> You're welcome.
> 
> Cheers,
> Edi.
> 



More information about the Tbnl-devel mailing list