help-gengetopt
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [help-gengetopt] parser.yy: sectiondesc TOK_MLSTRING


From: Gyozo, PAPP (VBuster)
Subject: RE: [help-gengetopt] parser.yy: sectiondesc TOK_MLSTRING
Date: Mon, 29 Nov 2004 11:18:48 +0100

Hi,

then we really need to add this hotfix to the check_possible_values() function 
in c_source.h_skel to handle NULL string pointers:


check_possible_values(const char *val, char *values[])
{
  int i, found;
  size_t len;

  if (!val)   /* otherwise strlen() crashes below */
    return 0; /* NULL means no argument for the option */

  for (found = i = 0, len = strlen(val); values[i]; ++i)
    ...

 

" -----Original Message-----
" From: Lorenzo Bettini [mailto:address@hidden
" Sent: Saturday, November 27, 2004 10:12 AM
" To: Users list for gengetopt
" Subject: Re: [help-gengetopt] parser.yy: sectiondesc TOK_MLSTRING
" 
" 
" Gyozo, PAPP (VBuster) wrote:
" > Hi there,
" > 
" > it would be nice if "sectiondesc" was multiple line string 
" as "purpose". After a short lookup, I've found that 
" sectiondef rule must be changed in parser.yy only (at least I hope):
" > 
" > sectiondef
" >           : TOK_SECTION quoted_string opt_sectiondesc
" >               {
" >                 gengetopt_set_section ($2, $3);
" >               }
" >           ;
" > 
" 
" Hi there
" 
" this version
" 
" http://rap.dsi.unifi.it/~bettini/gengetopt-2.13rc4.tar.gz
" 
" contains this modification (but it was also necessary to wrap the 
" definition -- previously only the description was wrapped)
" 
" cheers
"       Lorenzo (just come back :-)
" 
" -- 
" +-----------------------------------------------------+
" |  Lorenzo Bettini          ICQ# lbetto, 16080134     |
" |  PhD in Computer Science                            |
" |  Dip. Sistemi e Informatica, Univ. di Firenze       |
" |  Florence - Italy        (GNU/Linux User # 158233)  |
" |  Home Page        : http://www.lorenzobettini.it    |
" |  http://music.dsi.unifi.it         XKlaim language  |
" |  http://www.lorenzobettini.it/purple    Cover Band  |
" |  http://www.gnu.org/software/src-highlite           |
" |  http://www.gnu.org/software/gengetopt              |
" |  http://www.lorenzobettini.it/software/gengen       |
" |  http://www.lorenzobettini.it/software/doublecpp    |
" +-----------------------------------------------------+
" 
" 
" _______________________________________________
" Help-gengetopt mailing list
" address@hidden
" http://lists.gnu.org/mailman/listinfo/help-gengetopt
" 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]