summaryrefslogtreecommitdiff
path: root/client/file.c
diff options
context:
space:
mode:
authorRuss Allbery <rra@stanford.edu>2010-07-28 22:05:05 -0700
committerRuss Allbery <rra@stanford.edu>2010-07-28 22:05:05 -0700
commit5a48a5d5f7f2af72cf84114453748fbd2a337537 (patch)
tree052cd5178f6026994b94a6ff93fdfad1b2c00aa2 /client/file.c
parenta87062c0c60ba4daa3489966c85233c549a5c477 (diff)
Break wallet-rekey out into a separate client program
Build a separate wallet-rekey client that rekeys every keytab given on the command-line. Fix some coding style issues and add internal prototypes. Build the shared source for both clients into an uninstalled library to save compilation time.
Diffstat (limited to 'client/file.c')
-rw-r--r--client/file.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/client/file.c b/client/file.c
index 581d4a7..861da6a 100644
--- a/client/file.c
+++ b/client/file.c
@@ -46,9 +46,10 @@ overwrite_file(const char *name, const void *data, size_t length)
sysdie("close of %s failed (file probably truncated)", name);
}
+
/*
- * Given a filename, some data, and a length, write that data to the given
- * file safely, but overwrite any existing file by that name.
+ * Given a filename, some data, and a length, append that data to an existing
+ * file. Dies on any failure.
*/
void
append_file(const char *name, const void *data, size_t length)
@@ -70,6 +71,7 @@ append_file(const char *name, const void *data, size_t length)
sysdie("close of %s failed (file probably truncated)", name);
}
+
/*
* Given a filename, some data, and a length, write that data to the given
* file safely and atomically by creating file.new, writing the data, linking