Add krb5_storage_fsync().

We add a function to cause krb5_storage's to be sync'd to their backing
store.  For memory backed storages, this is a NOP.  For files, it calls
fsync on the file descriptor.
This commit is contained in:
Roland C. Dowdeswell
2012-05-28 13:14:55 +01:00
parent 8dc7c43a8b
commit df42274d96
6 changed files with 33 additions and 0 deletions

View File

@@ -40,6 +40,7 @@ struct krb5_storage_data {
ssize_t (*store)(struct krb5_storage_data*, const void*, size_t);
off_t (*seek)(struct krb5_storage_data*, off_t, int);
int (*trunc)(struct krb5_storage_data*, off_t);
int (*fsync)(struct krb5_storage_data*);
void (*free)(struct krb5_storage_data*);
krb5_flags flags;
int eof_code;