Openssl, Invalid arguments ' Candidates are: i

2020-07-28 11:30发布

I am using OpenSSL for a cuda project.

I just imported all the project from win to linux (Eclipse)

I solved all the dependencies except this annoying error:

Invalid arguments ' Candidates are: int BN_set_word(bignum_st *, ?) '

for this line:

BN_set_word(two, 2);

and the function itself says in the bn.h

int BN_set_word(BIGNUM *a, BN_ULONG w);

Where BN_ULONG is defined as:

#define BN_ULONG    unsigned long

Neither it works if I do something like

unsigned long q = 2;
BN_set_word(two, q);

Because it returns

Invalid arguments ' Candidates are: int BN_set_word(bignum_st *, ?) '

or

BN_ULONG q = 2;
BN_set_word(two, q);

that gives

Type 'BN_ULONG' could not be resolved

What is the problem?

1条回答
贪生不怕死
2楼-- · 2020-07-28 12:05

Sounds like you forgot to #include <openssl/bn.h>.

查看更多
登录 后发表回答