[BACK]Return to test-getsubopt.c CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / mandoc

Diff for /mandoc/test-getsubopt.c between version 1.1 and 1.2

version 1.1, 2011/07/24 18:15:14 version 1.2, 2014/01/04 01:11:00
Line 4 
Line 4 
   
 #include <stdlib.h>  #include <stdlib.h>
   
   extern char *suboptarg;
   
 int  int
 main(int argc, char **argv)  main(void)
 {  {
         getsubopt(argv, argv, argv);          char buf[] = "k=v";
         return 0;          char *options = buf;
           char token0[] = "k";
           char *const tokens[] = { token0, NULL };
           char *value = NULL;
           return( ! (0 == getsubopt(&options, tokens, &value)
               && suboptarg == buf && value == buf+2 && options == buf+3));
 }  }

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

CVSweb