p=malloc()!=null.......

Posted by gcc on Stack Overflow See other posts from Stack Overflow or by gcc
Published on 2010-04-28T19:43:07Z Indexed on 2010/04/28 19:47 UTC
Read the original article Hit count: 114

Filed under:
 char *p,*p1,*p2,*p3,*p4;

 for(;;)
  {

 if((p=malloc(10))!=NULL && (p1=malloc(20))!=NULL ......)


     break;
 }

Writing if(........) is too boring and long, are there any ways to make it simpler?

© Stack Overflow or respective owner

Related posts about c