~ubuntu-branches/ubuntu/maverick/strongswan/maverick

« back to all changes in this revision

Viewing changes to src/charon/plugins/uci/uci_parser.c

  • Committer: Bazaar Package Importer
  • Author(s): Rene Mayrhofer
  • Date: 2008-12-05 17:21:42 UTC
  • mfrom: (1.1.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20081205172142-9g77wgyzcj0blq7p
* New upstream release, fixes a MOBIKE issue.
  Closes: #507542: strongswan: endless loop
* Explicitly enable compilation with libcurl for CRL fetching
  Closes: #497756: strongswan: not compiled with curl support; crl 
                   fetching not available
* Enable compilation with SSH agent support.

Show diffs side-by-side

added added

removed removed

Lines of Context:
76
76
        
77
77
        va_start(args, this);
78
78
 
79
 
        /* name is first parameter */   
80
79
        value = va_arg(args, char**);
81
80
        if (value)
82
81
        {
83
 
                *value = uci_to_section(this->current)->type;
 
82
                if (uci_lookup(this->ctx, &element, this->package,
 
83
                                           this->current->name, "name") == UCI_OK)
 
84
                {       /* use "name" attribute as config name if available ... */
 
85
                        *value = uci_to_option(element)->value;
 
86
                }
 
87
                else
 
88
                {       /* ... or the section name becomes config name */
 
89
                        *value = uci_to_section(this->current)->type;
 
90
                }
84
91
        }
85
92
        
86
93
        /* followed by keyword parameters */