diff options
author | Joel Sing <jsing@cvs.openbsd.org> | 2014-08-30 15:14:04 +0000 |
---|---|---|
committer | Joel Sing <jsing@cvs.openbsd.org> | 2014-08-30 15:14:04 +0000 |
commit | 78d49f01d06cf0629a881ad403749530126a53bb (patch) | |
tree | 7a4f2c00ddcbee1522e6798f2d7bd00ade1d6a55 /usr.bin/openssl/apps.h | |
parent | e3e39c7a956e7161a7fbed4d5fc41e0bd29ac6f8 (diff) |
Move the callback function pointer outside the opt union so that the option
values are useable by the function. Also provide an option type that calls
a function without consuming/passing an argument.
Diffstat (limited to 'usr.bin/openssl/apps.h')
-rw-r--r-- | usr.bin/openssl/apps.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/openssl/apps.h b/usr.bin/openssl/apps.h index 277dcc36997..ea6be60a447 100644 --- a/usr.bin/openssl/apps.h +++ b/usr.bin/openssl/apps.h @@ -1,4 +1,4 @@ -/* $OpenBSD: apps.h,v 1.6 2014/08/28 14:15:28 jsing Exp $ */ +/* $OpenBSD: apps.h,v 1.7 2014/08/30 15:14:03 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -291,6 +291,7 @@ struct option { OPTION_ARG_FORMAT, OPTION_ARG_FUNC, OPTION_ARG_INT, + OPTION_FUNC, OPTION_FLAG, OPTION_FLAG_ORD, OPTION_VALUE, @@ -298,9 +299,9 @@ struct option { union { char **arg; int *flag; - int (*func)(struct option *opt, char *arg); int *value; } opt; + int (*func)(struct option *opt, char *arg); const int value; }; |