~ubuntu-branches/ubuntu/utopic/scons/utopic-proposed

« back to all changes in this revision

Viewing changes to engine/SCons/Sig/TimeStamp.py

  • Committer: Bazaar Package Importer
  • Author(s): Mark Brown
  • Date: 2004-08-24 08:57:22 UTC
  • mfrom: (0.2.1 upstream) (1.1.1 warty)
  • Revision ID: james.westby@ubuntu.com-20040824085722-hfk4f0pjbyu0ebxv
Tags: 0.96.1-1
New upstream release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
"""
7
7
 
8
8
#
9
 
# Copyright (c) 2001, 2002 Steven Knight
 
9
# Copyright (c) 2001, 2002, 2003, 2004 The SCons Foundation
10
10
#
11
11
# Permission is hereby granted, free of charge, to any person obtaining
12
12
# a copy of this software and associated documentation files (the
28
28
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
29
29
#
30
30
 
31
 
__revision__ = "src/engine/SCons/Sig/TimeStamp.py 0.D006 2002/03/28 02:47:47 software"
 
31
__revision__ = "/home/scons/scons/branch.0/baseline/src/engine/SCons/Sig/TimeStamp.py 0.96.1.D001 2004/08/23 09:55:29 knight"
32
32
 
33
33
def current(new, old):
34
34
    """Return whether a new timestamp is up-to-date with
63
63
 
64
64
def from_string(string):
65
65
    """Convert a string to a timestamp"""
66
 
    return int(string)
 
66
    try:
 
67
        return int(string)
 
68
    except ValueError:
 
69
        # if the signature isn't an int, then
 
70
        # the user probably just switched from
 
71
        # MD5 signatures to timestamp signatures,
 
72
        # so ignore the error:
 
73
        return None
67
74
 
68
75