A set of copyright headers
[mirror/userdir-ldap.git] / ud-generate
index fd0c53b..e5c1ae3 100755 (executable)
@@ -6,7 +6,7 @@
 #   Copyright (c) 2003-2004  James Troup <troup@debian.org>
 #   Copyright (c) 2004-2005,7  Joey Schulze <joey@infodrom.org>
 #   Copyright (c) 2001-2007  Ryan Murray <rmurray@debian.org>
-#   Copyright (c) 2008 Peter Palfrader <peter@palfrader.org>
+#   Copyright (c) 2008,2009,2010 Peter Palfrader <peter@palfrader.org>
 #   Copyright (c) 2008 Andreas Barth <aba@not.so.argh.org>
 #   Copyright (c) 2008 Mark Hymers <mhy@debian.org>
 #   Copyright (c) 2008 Luk Claes <luk@debian.org>
@@ -343,6 +343,8 @@ def GenSSHShadow():
       # Oops, something unspeakable happened.
       except IOError:
          Die(File, F, None)
+         # As neither masterFileName nor masterFile are defined at any point
+         # this will raise a NameError.
          Die(masterFileName, masterFile, None)
          raise
 
@@ -401,7 +403,7 @@ def GenSSHtarballs(userlist, SSHFiles, grouprevmap, target):
          lines.append(line)
       if not lines:
          continue # no keys for this host
-      contents = "\n".join(lines)
+      contents = "\n".join(lines) + "\n"
       to.size = len(contents)
       tf.addfile(to, StringIO(contents))