/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to mandos-ctl

  • Committer: Teddy Hogeborn
  • Date: 2013-06-23 15:13:06 UTC
  • Revision ID: teddy@recompile.se-20130623151306-3y4zwy76d95hcvpq
* mandos: Bug fix: Make boolean options work from the config file
          again.
          Bug fix: Make --no-ipv6 work again.
          Bug fix: Add extra magic to GnuTLS priority to make it work
          with current version of GnuTLS.
* mandos-options.xml (priority): Document new default value.
* mandos.conf (priority): - '' -
* plugins.d/mandos-client.xml (EXAMPLE): Minor grammar fix.

Show diffs side-by-side

added added

removed removed

Lines of Context:
199
199
    >>> string_to_delta("5m 30s")
200
200
    datetime.timedelta(0, 330)
201
201
    """
202
 
    value = datetime.timedelta(0)
203
 
    regexp = re.compile(r"(\d+)([dsmhw]?)")
204
202
    
205
203
    try:
206
204
        return rfc3339_duration_to_delta(interval)
207
205
    except ValueError:
208
206
        pass
209
207
    
 
208
    value = datetime.timedelta(0)
 
209
    regexp = re.compile(r"(\d+)([dsmhw]?)")
 
210
    
210
211
    for num, suffix in regexp.findall(interval):
211
212
        if suffix == "d":
212
213
            value += datetime.timedelta(int(num))