* Konrad Kleine wrote on Fri, Jun 13, 2008 at 17:32 +0200: > One of our principles is to have only one exit point in > functions, so in this point we would agree with you. On the > other hand, it is also possible to do it without "goto"s.
Yes, it is possible to `goto' without `gotos', sometimes there is some code like allocate_stuff(); do { if (!action1()) break; if (!action2()) break; if (!action3()) break; } while(0); free_stuff(); which may be considered a `hidden goto', maybe done because some keyword-based metric forbids using the keyword `goto', but I think logically it is the same. Since it is hidden personally I dislike this. Better clearly writing goto than emulating goto! Using a pattern like allocate_stuff(); if (!err) err = action1(); if (!err) err = action2(); if (!err) err = action3(); free_stuff(); in certain circumstances may also not be suited. Having some `func_exit:' label IMHO can improve readability of code (which is important to ease code reviews, for instance). So in short I think goto should not be demonized unconditionally; it depends on how it is used. just needed to say that :-) BTW, for passphrases to be entered by humans (without binary zeros inside) I think C-strings could be suited, the data type for some entry function could be `char *const passphrase' and for some function that uses it maybe `const char *const passphrase'. Is that right? oki, Steffen -- About Ingenico Throughout the world businesses rely on Ingenico for secure and expedient electronic transaction acceptance. Ingenico products leverage proven technology, established standards and unparalleled ergonomics to provide optimal reliability, versatility and usability. This comprehensive range of products is complemented by a global array of services and partnerships, enabling businesses in a number of vertical sectors to accept transactions anywhere their business takes them. www.ingenico.com This message may contain confidential and/or privileged information. If you are not the addressee or authorized to receive this for the addressee, you must not use, copy, disclose or take any action based on this message or any information herein. If you have received this message in error, please advise the sender immediately by reply e-mail and delete this message. Thank you for your cooperation. ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List openssl-users@openssl.org Automated List Manager [EMAIL PROTECTED]