[xmlsec] some changes for NSS support, some more pending

John Belmonte jvb at prairienet.org
Tue Jul 15 06:25:47 PDT 2003


You may want to create a style guide in the source package from what 
you've written here.

Regards,
-John


Aleksey wrote:
> 0) General comments on style:
> In best case, you  should have zero
>    warnings during compilation with "--enable-pedantic" configurure.in 
> option.
>    I cleared some of the warnings but there are a lot more to do.
>    - Please put explicit != NULL, != 0, etc. This makes code more easy 
> to read.
>    - Please put figure brackets {} even if you have only one operator.
>    For example
>          if(aaa)                 xmlFree(aaa);
>    should be
>          if(aaa != NULL) {
>                xmlFree(aaa);
>          }
>    - Please put round brackets for "return" like "return(0)"    - Please 
> round brackets in conditions like:
>          if(privkey == NULL || pubkey == NULL)
>      should be
>          if((privkey == NULL) || (pubkey == NULL))

...

>       - I really don't like the code structure here: several goto 
> labels, etc. May be it would be better
>    to split it in separate functions?



-- 
http:// if   l .o  /




More information about the xmlsec mailing list