> /* Initialize module */
> pdf_status_t pdf_crypt_init (void);
>
> Please remember in this point that, since the library should be
> thread-safe, you cannot maintain any global state.
>
However libgcrypt requires initialization. It must be called once
at startup. I will read the multithreading section from libgcrypt
reference.
Ok, thanks.
> /* Create a new cipher */
> pdf_crypt_t pdf_crypt_new (int method);
>
> Our current convention is to always return a pdf_status_t value in
> pdf_*_new functions, such as:
>
> pdf_status_t pdf_crypt_new (int method, pdf_crypt_t *crypt);
>
Ok, sorry. I took a look to pdf-text module reference and it doesn't
follow this convention:
pdf_text_t pdf_text_new (void)
I suppose we should fix it.
Hm, we should also fix it in the text module.