Reputation: 763
I am trying to write a multi-threaded program in which I need to call the function crypt. But the compiler throws this warning. Also it doesn't recognize crypt_data as well. Any ideas?
Upvotes: 1
Views: 1459
Reputation: 249093
Pre-process the source of your program, e.g. by running gcc -E
in place of gcc -c
. Look at the output to see if some/all/none of the crypt functions you expect are appearing in the declarations.
Upvotes: 1
Reputation: 51435
You need to include appropriate header file. In this case crypt.h
#include <crypt.h>
Upvotes: 3
Reputation: 121347
Declare the prototype for the function crypt (Forward declaration) Or include the header which has that.
Upvotes: 1