pdf-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [pdf-devel] Streams solution proposal


From: Juan Pedro Bolivar Puente
Subject: Re: [pdf-devel] Streams solution proposal
Date: Sat, 04 Oct 2008 20:29:01 +0200
User-agent: Mozilla-Thunderbird 2.0.0.16 (X11/20080724)

> Hmm. AFAIK the implementation should not emit more characters in that
> case. If it does that then it is a bug.
> 
> For me it makes sense to call flush into pdf_stm_destroy: it is
> what you get when you call fclose, for example.
>

Yep, you are right. My problem was with calling a finish, not a flush.

> Hmm. Consider that you want to ahex encode 20mb of data. You want to
> do it in chunks of 4k, so you call pdf_stm_write (my_buf, 4k). The
> internal filter chain will consume any output from 'my_buf' until it
> generates an EOF condition, but we certainly dont want to finish the
> filters at that point...
>

I didn't mean that EOF. I think that we can do it like this:

  - On write mode: Call pdf_stm_finish on pdf_stm_destroy.
  - On read mode: Call pdf_stm_finish on backend EOF.

If behaving that way I think that we can make the finishing process
transparent and correct. What do you think?

JP










reply via email to

[Prev in Thread] Current Thread [Next in Thread]