Export better list of errors.
[u/mdw/catacomb] / key-io.c
index 5f793d7..7ed0c2c 100644 (file)
--- a/key-io.c
+++ b/key-io.c
@@ -457,7 +457,7 @@ int key_open(key_file *f, const char *file, unsigned how,
  * Use:                Frees all the key data, without writing changes.
  */
 
-int key_discard(key_file *f)
+void key_discard(key_file *f)
 {
   hash_base *b;
   hash_iter i;
@@ -567,6 +567,7 @@ key *key_new(key_file *f, uint32 id, const char *type, time_t exp, int *err)
       k = 0;
     }
   }
+  *err = e;
   return (k);
 }