mirror of
https://git.libssh.org/projects/libssh.git
synced 2025-08-13 04:42:23 +03:00
Reformat make_string_bn().
git-svn-id: svn+ssh://svn.berlios.de/svnroot/repos/libssh/trunk@503 7dcaeef0-15fb-0310-b436-a5af3365683c
This commit is contained in:
11
libssh/dh.c
11
libssh/dh.c
@@ -350,17 +350,20 @@ STRING *make_bignum_string(bignum num) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
bignum make_string_bn(STRING *string){
|
bignum make_string_bn(STRING *string){
|
||||||
bignum bn;
|
bignum bn = NULL;
|
||||||
unsigned int len=string_len(string);
|
unsigned int len = string_len(string);
|
||||||
|
|
||||||
#ifdef DEBUG_CRYPTO
|
#ifdef DEBUG_CRYPTO
|
||||||
fprintf(stderr, "Importing a %d bits, %d bytes object ...\n",
|
fprintf(stderr, "Importing a %d bits, %d bytes object ...\n",
|
||||||
len * 8, len);
|
len * 8, len);
|
||||||
#endif /* DEBUG_CRYPTO */
|
#endif /* DEBUG_CRYPTO */
|
||||||
|
|
||||||
#ifdef HAVE_LIBGCRYPT
|
#ifdef HAVE_LIBGCRYPT
|
||||||
bignum_bin2bn(string->string,len,&bn);
|
bignum_bin2bn(string->string, len, &bn);
|
||||||
#elif defined HAVE_LIBCRYPTO
|
#elif defined HAVE_LIBCRYPTO
|
||||||
bn=bignum_bin2bn(string->string,len,NULL);
|
bn = bignum_bin2bn(string->string, len, NULL);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return bn;
|
return bn;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user