• [^] # Re: Sécurité ?

    Posté par (site web personnel) . En réponse à la dépêche Un nouveau serveur httpd : Ashd, A Sane HTTP Daemon. Évalué à 2.

    Je ne sais pas ce que tu appelles « évaluation fainéante » mais si tu fais allusion aux opérateurs || et &&, dont seul le membre gauche est évalué quand il est vrai ou faux (respectivement), alors tu te trompes : le standard précise ce comportement explicitement.


    Unlike the bitwise binary & operator, the && operator guarantees left-to-right evaluation; there is a sequence point after the evaluation of the first operand. If the first operand compares equal to 0, the second operand is not evaluated.

    (ISO/IEC 9899:1999, 6.5.13 § 4)