cjh> > No, no - rid the world of evil casts!
cjh> > Go with what's right everywhere, surely?
cjh> 
cjh> That's difficult when system library calls are often variously
cjh> and erroneously prototyped.  The alternative is wrappers
cjh> "my_select(...)" or evil casts on those function calls only.
cjh> Opinions?

Another solution (and I just checked this with a friend who knows the C
standards pretty damn well) could be to use `void *' for any argument
that is supposed to hold binary (non-text) data.  That would probably
be better than the `unsigned char *' that keeps on haunting us,
especially since any pointer will coerce implicitely to `void *', and
`void *' will coerce implicitely to any other pointer type.

Either that, or review the current prototypes.  For example, I see no
real reason for things like ASN1_STRING_set() to have an `unsigned
char *' is string input argument...  `char *' would do just as well,
and would leave us with less ambiguity (the third argument is pften
generated with strlen(), which normally takes a `char *'...).

Food for thoughts.  Comments?

-- 
Richard Levitte   \ Spannv�gen 38, II \ [EMAIL PROTECTED]
Redakteur@Stacken  \ S-161 43  BROMMA  \ T: +46-8-26 52 47
                    \      SWEDEN       \ or +46-708-26 53 44
Procurator Odiosus Ex Infernis             -- [EMAIL PROTECTED]

Unsolicited commercial email is subject to an archival fee of $400.
See <http://www.stacken.kth.se/~levitte/mail/> for more info.

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
Development Mailing List                       [EMAIL PROTECTED]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to