提交 c06648f7 编写于 作者: B Bodo Möller

Fix C code generate by 'openssl dsaparam -C'.

上级 cd56182b
...@@ -3,6 +3,10 @@ ...@@ -3,6 +3,10 @@
Changes between 0.9.6 and 0.9.7 [xx XXX 2000] Changes between 0.9.6 and 0.9.7 [xx XXX 2000]
*) Fix C code generated by 'openssl dsaparam -C': If a BN_bin2bn
call failed, free the DSA structure.
[Bodo Moeller]
*) Add another call level for memory allocation routines, thereby *) Add another call level for memory allocation routines, thereby
allowing memory allocation callbacks that can be given file allowing memory allocation callbacks that can be given file
name and line number information. The basic functionality name and line number information. The basic functionality
......
...@@ -338,7 +338,7 @@ bad: ...@@ -338,7 +338,7 @@ bad:
printf("\tdsa->g=BN_bin2bn(dsa%d_g,sizeof(dsa%d_g),NULL);\n", printf("\tdsa->g=BN_bin2bn(dsa%d_g,sizeof(dsa%d_g),NULL);\n",
bits_p,bits_p); bits_p,bits_p);
printf("\tif ((dsa->p == NULL) || (dsa->q == NULL) || (dsa->g == NULL))\n"); printf("\tif ((dsa->p == NULL) || (dsa->q == NULL) || (dsa->g == NULL))\n");
printf("\t\treturn(NULL);\n"); printf("\t\t{ DSA_free(dsa); return(NULL); }\n");
printf("\treturn(dsa);\n\t}\n"); printf("\treturn(dsa);\n\t}\n");
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册