From 49a6a67825dd906dd3954d89449cf414223296be Mon Sep 17 00:00:00 2001 From: tb <> Date: Sat, 2 Jun 2018 04:45:21 +0000 Subject: Add a const qualifier to the argument of UI_method_get_closer(), UI_method_get_flusher(), UI_method_get_opener(), UI_method_get_prompt_constructor(), UI_method_get_reader(), and UI_method_get_writer(). tested in a bulk build by sthen ok jsing --- src/lib/libcrypto/ui/ui.h | 14 +++++++------- src/lib/libcrypto/ui/ui_lib.c | 14 +++++++------- 2 files changed, 14 insertions(+), 14 deletions(-) (limited to 'src') diff --git a/src/lib/libcrypto/ui/ui.h b/src/lib/libcrypto/ui/ui.h index 8ae0dd5e75..8035fc2baa 100644 --- a/src/lib/libcrypto/ui/ui.h +++ b/src/lib/libcrypto/ui/ui.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ui.h,v 1.10 2018/05/19 11:03:33 tb Exp $ */ +/* $OpenBSD: ui.h,v 1.11 2018/06/02 04:45:21 tb Exp $ */ /* Written by Richard Levitte (richard@levitte.org) for the OpenSSL * project 2001. */ @@ -312,12 +312,12 @@ int UI_method_set_flusher(UI_METHOD *method, int (*flusher)(UI *ui)); int UI_method_set_reader(UI_METHOD *method, int (*reader)(UI *ui, UI_STRING *uis)); int UI_method_set_closer(UI_METHOD *method, int (*closer)(UI *ui)); int UI_method_set_prompt_constructor(UI_METHOD *method, char *(*prompt_constructor)(UI* ui, const char* object_desc, const char* object_name)); -int (*UI_method_get_opener(UI_METHOD *method))(UI*); -int (*UI_method_get_writer(UI_METHOD *method))(UI*, UI_STRING*); -int (*UI_method_get_flusher(UI_METHOD *method))(UI*); -int (*UI_method_get_reader(UI_METHOD *method))(UI*, UI_STRING*); -int (*UI_method_get_closer(UI_METHOD *method))(UI*); -char * (*UI_method_get_prompt_constructor(UI_METHOD *method))(UI*, const char*, const char*); +int (*UI_method_get_opener(const UI_METHOD *method))(UI*); +int (*UI_method_get_writer(const UI_METHOD *method))(UI*, UI_STRING*); +int (*UI_method_get_flusher(const UI_METHOD *method))(UI*); +int (*UI_method_get_reader(const UI_METHOD *method))(UI*, UI_STRING*); +int (*UI_method_get_closer(const UI_METHOD *method))(UI*); +char * (*UI_method_get_prompt_constructor(const UI_METHOD *method))(UI*, const char*, const char*); /* The following functions are helpers for method writers to access relevant data from a UI_STRING. */ diff --git a/src/lib/libcrypto/ui/ui_lib.c b/src/lib/libcrypto/ui/ui_lib.c index 8ad5580261..06b29b8cee 100644 --- a/src/lib/libcrypto/ui/ui_lib.c +++ b/src/lib/libcrypto/ui/ui_lib.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ui_lib.c,v 1.33 2018/05/19 11:03:33 tb Exp $ */ +/* $OpenBSD: ui_lib.c,v 1.34 2018/06/02 04:45:21 tb Exp $ */ /* Written by Richard Levitte (richard@levitte.org) for the OpenSSL * project 2001. */ @@ -666,7 +666,7 @@ UI_method_set_prompt_constructor(UI_METHOD *method, } int -(*UI_method_get_opener(UI_METHOD * method))(UI *) +(*UI_method_get_opener(const UI_METHOD * method))(UI *) { if (method) return method->ui_open_session; @@ -675,7 +675,7 @@ int } int -(*UI_method_get_writer(UI_METHOD *method))(UI *, UI_STRING *) +(*UI_method_get_writer(const UI_METHOD *method))(UI *, UI_STRING *) { if (method) return method->ui_write_string; @@ -684,7 +684,7 @@ int } int -(*UI_method_get_flusher(UI_METHOD *method)) (UI *) +(*UI_method_get_flusher(const UI_METHOD *method)) (UI *) { if (method) return method->ui_flush; @@ -693,7 +693,7 @@ int } int -(*UI_method_get_reader(UI_METHOD *method))(UI *, UI_STRING *) +(*UI_method_get_reader(const UI_METHOD *method))(UI *, UI_STRING *) { if (method) return method->ui_read_string; @@ -702,7 +702,7 @@ int } int -(*UI_method_get_closer(UI_METHOD *method))(UI *) +(*UI_method_get_closer(const UI_METHOD *method))(UI *) { if (method) return method->ui_close_session; @@ -711,7 +711,7 @@ int } char * -(*UI_method_get_prompt_constructor(UI_METHOD *method))(UI *, const char *, +(*UI_method_get_prompt_constructor(const UI_METHOD *method))(UI *, const char *, const char *) { if (method) -- cgit v1.2.3-55-g6feb