On Tue, Jan 24, 2012 at 11:42:49AM +0100, Denys Vlasenko wrote:
> On 01/24/2012 11:24 AM, Dmitry V. Levin wrote:
> >On Tue, Jan 24, 2012 at 10:10:05AM +0100, Denys Vlasenko wrote:
> >> msg = NULL;
> >> vasprintf(&msg, fmt, p);
> >> if (msg) {
> >
> >I'd rather replace these three lines with
> >
> > if (vasprintf(&msg, fmt, p)>= 0) {
>
> We can combine both just to be 200% paranoid-grade sure:
>
> if (vasprintf(&msg, fmt, p) >= 0 && msg) ...No need, the return code check is enough. -- ldv
pgpZOnwpj2yNP.pgp
Description: PGP signature
------------------------------------------------------------------------------ Keep Your Developer Skills Current with LearnDevNow! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________ Strace-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/strace-devel
