crypto/bn/bn_nist.c:591: error: UNINITIALIZED_VALUE
  The value read from t_d[_] was never initialized.
Showing all 1 steps of the trace


crypto/bn/bn_nist.c:591:2: 
589.   	BN_ULONG t_d[BN_NIST_224_TOP];
590.   
591. > 	nist_set_224(t_d, buf.bn, 10, 9, 8, 7, 0, 0, 0);
592.   	carry = (int)bn_add_words(r_d, r_d, t_d, BN_NIST_224_TOP);
593.   	nist_set_224(t_d, buf.bn, 0, 13, 12, 11, 0, 0, 0);

int BN_nist_mod_224(BIGNUM *r, const BIGNUM *a, const BIGNUM *field,
	BN_CTX *ctx)
	{
	int	top = a->top, i;
	int	carry;
	BN_ULONG *r_d, *a_d = a->d;
	union	{
		BN_ULONG	bn[BN_NIST_224_TOP];
		unsigned int	ui[BN_NIST_224_TOP*sizeof(BN_ULONG)/sizeof(unsigned int)];
		} buf;
	BN_ULONG c_d[BN_NIST_224_TOP],
		*res;
	PTR_SIZE_INT mask;
	union { bn_addsub_f f; PTR_SIZE_INT p; } u;
	static const BIGNUM _bignum_nist_p_224_sqr = {
		(BN_ULONG *)_nist_p_224_sqr,
		sizeof(_nist_p_224_sqr)/sizeof(_nist_p_224_sqr[0]),
		sizeof(_nist_p_224_sqr)/sizeof(_nist_p_224_sqr[0]),
		0,BN_FLG_STATIC_DATA };
	field = &_bignum_nist_p_224;
 	if (BN_is_negative(a) || BN_ucmp(a,&_bignum_nist_p_224_sqr)>=0)
		return BN_nnmod(r, a, field, ctx);
	i = BN_ucmp(field, a);
	if (i == 0)
		{
		BN_zero(r);
		return 1;
		}
	else if (i > 0)
		return (r == a)? 1 : (BN_copy(r ,a) != NULL);
	if (r != a)
		{
		if (!bn_wexpand(r, BN_NIST_224_TOP))
			return 0;
		r_d = r->d;
		nist_cp_bn(r_d, a_d, BN_NIST_224_TOP);
		}
	else
		r_d = a_d;
#if BN_BITS2==64
	nist_cp_bn_0(c_d, a_d + (BN_NIST_224_TOP-1), top - (BN_NIST_224_TOP-1), BN_NIST_224_TOP);
	nist_set_224(buf.bn, c_d, 14, 13, 12, 11, 10, 9, 8);
	r_d[BN_NIST_224_TOP-1] &= BN_MASK2l;
#else
	nist_cp_bn_0(buf.bn, a_d + BN_NIST_224_TOP, top - BN_NIST_224_TOP, BN_NIST_224_TOP);
#endif
#if defined(NIST_INT64) && BN_BITS2!=64
	{
	NIST_INT64		acc;
	unsigned int		*rp=(unsigned int *)r_d;
	const unsigned int	*bp=(const unsigned int *)buf.ui;
	acc  = rp[0];	acc -= bp[7-7];
			acc -= bp[11-7]; rp[0] = (unsigned int)acc; acc >>= 32;
	acc += rp[1];	acc -= bp[8-7];
			acc -= bp[12-7]; rp[1] = (unsigned int)acc; acc >>= 32;
	acc += rp[2];	acc -= bp[9-7];
			acc -= bp[13-7]; rp[2] = (unsigned int)acc; acc >>= 32;
	acc += rp[3];	acc += bp[7-7];
			acc += bp[11-7];
			acc -= bp[10-7]; rp[3] = (unsigned int)acc; acc>>= 32;
	acc += rp[4];	acc += bp[8-7];
			acc += bp[12-7];
			acc -= bp[11-7]; rp[4] = (unsigned int)acc; acc >>= 32;
	acc += rp[5];	acc += bp[9-7];
			acc += bp[13-7];
			acc -= bp[12-7]; rp[5] = (unsigned int)acc; acc >>= 32;
	acc += rp[6];	acc += bp[10-7];
			acc -= bp[13-7]; rp[6] = (unsigned int)acc;
	carry = (int)(acc>>32);
# if BN_BITS2==64
	rp[7] = carry;
# endif
	}
#else
	{
	BN_ULONG t_d[BN_NIST_224_TOP];
	nist_set_224(t_d, buf.bn, 10, 9, 8, 7, 0, 0, 0);
	carry = (int)bn_add_words(r_d, r_d, t_d, BN_NIST_224_TOP);
	nist_set_224(t_d, buf.bn, 0, 13, 12, 11, 0, 0, 0);
	carry += (int)bn_add_words(r_d, r_d, t_d, BN_NIST_224_TOP);
	nist_set_224(t_d, buf.bn, 13, 12, 11, 10, 9, 8, 7);
	carry -= (int)bn_sub_words(r_d, r_d, t_d, BN_NIST_224_TOP);
	nist_set_224(t_d, buf.bn, 0, 0, 0, 0, 13, 12, 11);
	carry -= (int)bn_sub_words(r_d, r_d, t_d, BN_NIST_224_TOP);
#if BN_BITS2==64
	carry = (int)(r_d[BN_NIST_224_TOP-1]>>32);
#endif
	}
#endif
	u.f = bn_sub_words;
	if (carry > 0)
		{
		carry = (int)bn_sub_words(r_d,r_d,_nist_p_224[carry-1],BN_NIST_224_TOP);
#if BN_BITS2==64
		carry=(int)(~(r_d[BN_NIST_224_TOP-1]>>32))&1;
#endif
		}
	else if (carry < 0)
		{
		carry = (int)bn_add_words(r_d,r_d,_nist_p_224[-carry-1],BN_NIST_224_TOP);
		mask = 0-(PTR_SIZE_INT)carry;
		u.p = ((PTR_SIZE_INT)bn_sub_words&mask) |
		 ((PTR_SIZE_INT)bn_add_words&~mask);
		}
	else
		carry = 1;
	mask  = 0-(PTR_SIZE_INT)(*u.f)(c_d,r_d,_nist_p_224[0],BN_NIST_224_TOP);
	mask &= 0-(PTR_SIZE_INT)carry;
	res   = c_d;
	res   = (BN_ULONG *)(((PTR_SIZE_INT)res&~mask) |
	 ((PTR_SIZE_INT)r_d&mask));
	nist_cp_bn(r_d, res, BN_NIST_224_TOP);
	r->top = BN_NIST_224_TOP;
	bn_correct_top(r);
	return 1;
	}
['int BN_nist_mod_224(BIGNUM *r, const BIGNUM *a, const BIGNUM *field,\n\tBN_CTX *ctx)\n\t{\n\tint\ttop = a->top, i;\n\tint\tcarry;\n\tBN_ULONG *r_d, *a_d = a->d;\n\tunion\t{\n\t\tBN_ULONG\tbn[BN_NIST_224_TOP];\n\t\tunsigned int\tui[BN_NIST_224_TOP*sizeof(BN_ULONG)/sizeof(unsigned int)];\n\t\t} buf;\n\tBN_ULONG c_d[BN_NIST_224_TOP],\n\t\t*res;\n\tPTR_SIZE_INT mask;\n\tunion { bn_addsub_f f; PTR_SIZE_INT p; } u;\n\tstatic const BIGNUM _bignum_nist_p_224_sqr = {\n\t\t(BN_ULONG *)_nist_p_224_sqr,\n\t\tsizeof(_nist_p_224_sqr)/sizeof(_nist_p_224_sqr[0]),\n\t\tsizeof(_nist_p_224_sqr)/sizeof(_nist_p_224_sqr[0]),\n\t\t0,BN_FLG_STATIC_DATA };\n\tfield = &_bignum_nist_p_224;\n \tif (BN_is_negative(a) || BN_ucmp(a,&_bignum_nist_p_224_sqr)>=0)\n\t\treturn BN_nnmod(r, a, field, ctx);\n\ti = BN_ucmp(field, a);\n\tif (i == 0)\n\t\t{\n\t\tBN_zero(r);\n\t\treturn 1;\n\t\t}\n\telse if (i > 0)\n\t\treturn (r == a)? 1 : (BN_copy(r ,a) != NULL);\n\tif (r != a)\n\t\t{\n\t\tif (!bn_wexpand(r, BN_NIST_224_TOP))\n\t\t\treturn 0;\n\t\tr_d = r->d;\n\t\tnist_cp_bn(r_d, a_d, BN_NIST_224_TOP);\n\t\t}\n\telse\n\t\tr_d = a_d;\n#if BN_BITS2==64\n\tnist_cp_bn_0(c_d, a_d + (BN_NIST_224_TOP-1), top - (BN_NIST_224_TOP-1), BN_NIST_224_TOP);\n\tnist_set_224(buf.bn, c_d, 14, 13, 12, 11, 10, 9, 8);\n\tr_d[BN_NIST_224_TOP-1] &= BN_MASK2l;\n#else\n\tnist_cp_bn_0(buf.bn, a_d + BN_NIST_224_TOP, top - BN_NIST_224_TOP, BN_NIST_224_TOP);\n#endif\n#if defined(NIST_INT64) && BN_BITS2!=64\n\t{\n\tNIST_INT64\t\tacc;\n\tunsigned int\t\t*rp=(unsigned int *)r_d;\n\tconst unsigned int\t*bp=(const unsigned int *)buf.ui;\n\tacc  = rp[0];\tacc -= bp[7-7];\n\t\t\tacc -= bp[11-7]; rp[0] = (unsigned int)acc; acc >>= 32;\n\tacc += rp[1];\tacc -= bp[8-7];\n\t\t\tacc -= bp[12-7]; rp[1] = (unsigned int)acc; acc >>= 32;\n\tacc += rp[2];\tacc -= bp[9-7];\n\t\t\tacc -= bp[13-7]; rp[2] = (unsigned int)acc; acc >>= 32;\n\tacc += rp[3];\tacc += bp[7-7];\n\t\t\tacc += bp[11-7];\n\t\t\tacc -= bp[10-7]; rp[3] = (unsigned int)acc; acc>>= 32;\n\tacc += rp[4];\tacc += bp[8-7];\n\t\t\tacc += bp[12-7];\n\t\t\tacc -= bp[11-7]; rp[4] = (unsigned int)acc; acc >>= 32;\n\tacc += rp[5];\tacc += bp[9-7];\n\t\t\tacc += bp[13-7];\n\t\t\tacc -= bp[12-7]; rp[5] = (unsigned int)acc; acc >>= 32;\n\tacc += rp[6];\tacc += bp[10-7];\n\t\t\tacc -= bp[13-7]; rp[6] = (unsigned int)acc;\n\tcarry = (int)(acc>>32);\n# if BN_BITS2==64\n\trp[7] = carry;\n# endif\n\t}\n#else\n\t{\n\tBN_ULONG t_d[BN_NIST_224_TOP];\n\tnist_set_224(t_d, buf.bn, 10, 9, 8, 7, 0, 0, 0);\n\tcarry = (int)bn_add_words(r_d, r_d, t_d, BN_NIST_224_TOP);\n\tnist_set_224(t_d, buf.bn, 0, 13, 12, 11, 0, 0, 0);\n\tcarry += (int)bn_add_words(r_d, r_d, t_d, BN_NIST_224_TOP);\n\tnist_set_224(t_d, buf.bn, 13, 12, 11, 10, 9, 8, 7);\n\tcarry -= (int)bn_sub_words(r_d, r_d, t_d, BN_NIST_224_TOP);\n\tnist_set_224(t_d, buf.bn, 0, 0, 0, 0, 13, 12, 11);\n\tcarry -= (int)bn_sub_words(r_d, r_d, t_d, BN_NIST_224_TOP);\n#if BN_BITS2==64\n\tcarry = (int)(r_d[BN_NIST_224_TOP-1]>>32);\n#endif\n\t}\n#endif\n\tu.f = bn_sub_words;\n\tif (carry > 0)\n\t\t{\n\t\tcarry = (int)bn_sub_words(r_d,r_d,_nist_p_224[carry-1],BN_NIST_224_TOP);\n#if BN_BITS2==64\n\t\tcarry=(int)(~(r_d[BN_NIST_224_TOP-1]>>32))&1;\n#endif\n\t\t}\n\telse if (carry < 0)\n\t\t{\n\t\tcarry = (int)bn_add_words(r_d,r_d,_nist_p_224[-carry-1],BN_NIST_224_TOP);\n\t\tmask = 0-(PTR_SIZE_INT)carry;\n\t\tu.p = ((PTR_SIZE_INT)bn_sub_words&mask) |\n\t\t ((PTR_SIZE_INT)bn_add_words&~mask);\n\t\t}\n\telse\n\t\tcarry = 1;\n\tmask  = 0-(PTR_SIZE_INT)(*u.f)(c_d,r_d,_nist_p_224[0],BN_NIST_224_TOP);\n\tmask &= 0-(PTR_SIZE_INT)carry;\n\tres   = c_d;\n\tres   = (BN_ULONG *)(((PTR_SIZE_INT)res&~mask) |\n\t ((PTR_SIZE_INT)r_d&mask));\n\tnist_cp_bn(r_d, res, BN_NIST_224_TOP);\n\tr->top = BN_NIST_224_TOP;\n\tbn_correct_top(r);\n\treturn 1;\n\t}']