Debian Codegraph @

debian/rust-vendor/aws-lc-sys/aws-lc/crypto/ui/ui.c

raw
1 // Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
2 // SPDX-License-Identifier: Apache-2.0 OR ISC
3
4 // AWS-LC does not support the UI APIs. These functions always fail at runtime.
5 // This file provides no-op implementations of several UI functions that return
6 // failure when called. This allows compilation to succeed for projects that use
7 // these functions for non-essential operations.
8
9 #include "openssl/ui.h"
10 #include "openssl/mem.h"
11
12 UI *UI_new(void) {
13 return NULL;
14 }
15
16 void UI_free(UI *ui) {
17 OPENSSL_free(ui);
18 }
19
20 int UI_add_input_string(UI *ui, const char *prompt, int flags,
21 char *result_buf, int minsize, int maxsize) {
22 return -1;
23 }
24 int UI_add_verify_string(UI *ui, const char *prompt, int flags,
25 char *result_buf, int minsize, int maxsize, const char *test_buf) {
26 return -1;
27 }
28
29 int UI_add_info_string(UI *ui, const char *text) {
30 return -1;
31 }
32
33 int UI_process(UI *ui) {
34 return -1;
35 }