[gnutls-dev] API comments

Simon Josefsson jas@vic20.blipp.com
Wed Dec 5 09:28:03 2001


On Sun, 2 Dec 2001, Nikos Mavroyanopoulos wrote:

> On Sun, 02 Dec 2001 01:09:47 +0100 Simon Josefsson <jas@extundo.com> wrote:
>
> > Some comments on the API:
> Since you've worked with other TLS APIs I'd like to hear more
> comments about the gnutls api :)
>
> If you think some things are done better in other implementations
> just say it!

For one thing, using "..." is horrible.  It makes it difficult to read the
values from e.g. a config file and then pass on to the function.  Also it
is much more difficult to do function bindings in other languages etc.
IMHO the "..."  feature of C should only ever be used when writing a
wrapper around printf() or other already existing functions that use
"...".

It seems as if it would be possible to solve this by using some other
value of GNUTLS_LIST though. Maybe a integer array instead.

(Feel free to disagree, of course, this was only my initial reaction.)