diff options
author | Russ Allbery <rra@stanford.edu> | 2007-10-05 02:15:27 +0000 |
---|---|---|
committer | Russ Allbery <rra@stanford.edu> | 2007-10-05 02:15:27 +0000 |
commit | f21fba65f194ff26bf72e23f0db311314529720b (patch) | |
tree | ce454a33292244ad130962ab9da7f667fe57d1ec /client/internal.h | |
parent | fe56c09a7feeb2d1c9cd699fda07e145c4c354a2 (diff) |
Refactor the remctl calls in the wallet client to share a common routine.
Diffstat (limited to 'client/internal.h')
-rw-r--r-- | client/internal.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/client/internal.h b/client/internal.h index 092240e..960554e 100644 --- a/client/internal.h +++ b/client/internal.h @@ -27,6 +27,14 @@ struct remctl; BEGIN_DECLS +/* Given a remctl object, run a remctl command. If data is non-NULL, saves + the standard output from the command into data with the length in length. + Otherwise, prints it to standard output. Either way, prints standard error + output and errors to standard error and returns the exit status or 255 for + a remctl internal error. */ +int run_command(struct remctl *, const char **command, char **data, + size_t *length); + /* Given a remctl object, the type for the wallet interface, the name of a keytab object, and a file name, call the correct wallet commands to download a keytab and write it to that file. */ |