Hi Henrik,

> to convert the HTML parts back to HTML through the use of the xml
> library, to store the text in the database as is. I do not want to
> output the result of course so I use pipe to grab it instead, like so:

Using lib/xml.l for parsing html/sgml is not reliable unless the
html/xhtml you are trying to parse is well formed xml (which is quite
rare on the web usualy).

> (pipe (xml Html) (till NIL T))
> This works fine when I try the "raw" functionality without using the
> http server. However, when exactly the same code is called in the real
> application (within the context of the http server) the above results
> in NIL instead of the HTML. Trying (trace 'pipe) in the server
> application just locks up the whole process, doing it in the testcode
> gives me this example though:
> I've had exactly the same behavior happen to me when calling a ruby
> script through (call), It was resolved by using (in) instead, like
> this (which works):
> (in (list 'ruby "projects/rss-reader/htmldecode.rb" Str) (till))

I found the same problem when using bcrypt for password protection as
discussed in

   (unless (<= 8 (length (pipe (prin Salt) (line T))) 56)
      (quit "Length of Salt must be from 8 to 56" Salt))

'pipe' worked fine except when run in a server which returned NIL.

> Why is this happening and how can it be resolved, any ideas?
> Could the problem be that xml is outputting unchunked to pipe and the
> http server chokes on this?

I am curious too.  I guess it has something to do with the way
picolisp handles files during pipe or call?



Reply via email to