crypto/engine/hw_ncipher.c:1225: error: UNINITIALIZED_VALUE
  The value read from answer[_] was never initialized.
Showing all 1 steps of the trace


crypto/engine/hw_ncipher.c:1225:21: 
1223.                           ok = UI_process(ui);
1224.                   UI_free(ui);
1225. >                 if (strchr("Cc",answer[0]) == 0)
1226.                           ok = 1;
1227.                   }

static int hwcrhk_insert_card(const char *prompt_info,
		      const char *wrong_info,
		      HWCryptoHook_PassphraseContext *ppctx,
		      HWCryptoHook_CallerContext *cactx)
        {
        int ok = 1;
        UI *ui;
	void *callback_data = NULL;
        UI_METHOD *ui_method = NULL;
        if (cactx)
                {
                if (cactx->ui_method)
                        ui_method = cactx->ui_method;
		if (cactx->callback_data)
			callback_data = cactx->callback_data;
                }
	if (ppctx)
		{
                if (ppctx->ui_method)
                        ui_method = ppctx->ui_method;
		if (ppctx->callback_data)
			callback_data = ppctx->callback_data;
		}
	if (ui_method == NULL)
		{
		ENGINEerr(ENGINE_F_HWCRHK_INSERT_CARD,ENGINE_R_NO_CALLBACK);
		return -1;
		}
        ui = UI_new_method(ui_method);
        if (ui)
                {
                char answer[10];
                char buf[BUFSIZ];
                if (wrong_info)
                        BIO_snprintf(buf, sizeof(buf)-1,
                                "Current card: \"%s\"\n", wrong_info);
                ok = UI_dup_info_string(ui, buf);
                if (ok == 0 && prompt_info)
                        {
                        BIO_snprintf(buf, sizeof(buf)-1,
                                "Insert card \"%s\"\n then hit <enter> or C<enter> to cancel\n", prompt_info);
                        ok = UI_dup_input_string(ui, buf, 1,
                                answer, 0, sizeof(answer)-1);
                        }
                UI_add_user_data(ui, callback_data);
                if (ok == 0)
                        ok = UI_process(ui);
                UI_free(ui);
                if (strchr("Cc",answer[0]) == 0)
                        ok = 1;
                }
        if (ok == 0)
                return 0;
        return -1;
        }
['static int hwcrhk_insert_card(const char *prompt_info,\n\t\t      const char *wrong_info,\n\t\t      HWCryptoHook_PassphraseContext *ppctx,\n\t\t      HWCryptoHook_CallerContext *cactx)\n        {\n        int ok = 1;\n        UI *ui;\n\tvoid *callback_data = NULL;\n        UI_METHOD *ui_method = NULL;\n        if (cactx)\n                {\n                if (cactx->ui_method)\n                        ui_method = cactx->ui_method;\n\t\tif (cactx->callback_data)\n\t\t\tcallback_data = cactx->callback_data;\n                }\n\tif (ppctx)\n\t\t{\n                if (ppctx->ui_method)\n                        ui_method = ppctx->ui_method;\n\t\tif (ppctx->callback_data)\n\t\t\tcallback_data = ppctx->callback_data;\n\t\t}\n\tif (ui_method == NULL)\n\t\t{\n\t\tENGINEerr(ENGINE_F_HWCRHK_INSERT_CARD,ENGINE_R_NO_CALLBACK);\n\t\treturn -1;\n\t\t}\n        ui = UI_new_method(ui_method);\n        if (ui)\n                {\n                char answer[10];\n                char buf[BUFSIZ];\n                if (wrong_info)\n                        BIO_snprintf(buf, sizeof(buf)-1,\n                                "Current card: \\"%s\\"\\n", wrong_info);\n                ok = UI_dup_info_string(ui, buf);\n                if (ok == 0 && prompt_info)\n                        {\n                        BIO_snprintf(buf, sizeof(buf)-1,\n                                "Insert card \\"%s\\"\\n then hit <enter> or C<enter> to cancel\\n", prompt_info);\n                        ok = UI_dup_input_string(ui, buf, 1,\n                                answer, 0, sizeof(answer)-1);\n                        }\n                UI_add_user_data(ui, callback_data);\n                if (ok == 0)\n                        ok = UI_process(ui);\n                UI_free(ui);\n                if (strchr("Cc",answer[0]) == 0)\n                        ok = 1;\n                }\n        if (ok == 0)\n                return 0;\n        return -1;\n        }']