Jürgen Herz wrote: > But I can't see how to get from the image URL of scheme mailbox://, > news:// or imap:// to a nsIInputStream.
The best thing to do here is to create a channel for the nsIURI, then asyncOpen it and have a stream listener to read the data. If you really need to buffer the data up into a single stream, you could either use open() instead of asyncOpen() or copy the data into a pipe in your streamlistener. The latter is probably better in terms of playing nice with other code. Note that either way the event loop will spin as you get your data, and you need to deal with that (e.g. your code might be reentered). -Boris _______________________________________________ dev-tech-network mailing list [email protected] https://lists.mozilla.org/listinfo/dev-tech-network
